-
Notifications
You must be signed in to change notification settings - Fork 1
Weatherstream Export service
This service is designed to export weather data in a WeatherStream (.wxs) format, for further use in Fire Behavior models, such as Flammap/Farsite.
The weather stream export is implemented as a Web Processing Service (WPS) module as part of Geoserver
Weather data is extracted from RTMA, NDFD, and GFS gridded datasets covering the Continental US. The RTMA dataset represents weather observations over the last 10 days, and the NDFD and GFS datasets are weather forecasts:
RTMA and NDFD provide data at 2500m pixel resolution, while GFS pixels represent 0.25 deg area
Gridded weather data is currently provided for the Continental US.
This service can be accessed from aws.wfas.net/geoserver/web
-
Go to the WPS Request Bulder page.
-
Choose gs:WeatherStream from the dropdown list:
-
User inputs:
- Enter desired longitude and latitude coordinates (mandatory). The geographic coordinates are presumed to be within the extent for the lower 48 US. If not, the process will terminate.
- Optional--true or false if English units are desired. Default is true.
- Optional--the name of the dataset: rtma, ndfd, gfs, or all. Default is all for all three datasets.
- Optional--start date in 'yyyy-mm-dd' or 'yyyy-mm-dd HH:MM:SS' format. Time zone is assigned based on the input coordinates.
- Optional--end date in 'yyyy-mm-dd' or 'yyyy-mm-dd HH:MM:SS' format. Time zone is assigned based on the input coordinates.
The CSV output will be formatted in the Weatherstream format for Flammap/Farsite.
It is possible to extract weather data by using a HTTP Get request, either via a browser, or a command line utility such as curl or wget (useful for scripted requests). The input parameters are provided as key/value pairs as part of the URL, and separated by a semicolon (;). The symbols '+' or '%20' are used to encode spaces in parameter names and values.
Below is an example of such a request using curl, where the extracted data is saved to result.csv. Note that only the Longitude and Latitude parameters are mandatory, others are optional:
curl "http://aws.wfas.net/geoserver/ows?service=WPS
&version=1.0.0
&request=execute
&identifier=gs:WeatherStream
&DataInputs=Longitude=-114;Latitude=45;
Archive=ndfd;
English+units=true;
Start+date=2020-05-20+03:00:00;
End+date=2020-05-21+10:00:00
&RawDataOutput=output" -o result.csv
It is possible to execute a command line POST request. This is very convenient for automated requests where the results can be used as part of a processing chain.
The request should be in the form of XML formatted, OGC compliant Web Processing Service request. Only the Longitude and Latitude inputs are mandatory, the others are optional and can be omitted. XML example:
<?xml version="1.0" encoding="UTF-8"?><wps:Execute version="1.0.0" service="WPS" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.opengis.net/wps/1.0.0" xmlns:wfs="http://www.opengis.net/wfs" xmlns:wps="http://www.opengis.net/wps/1.0.0" xmlns:ows="http://www.opengis.net/ows/1.1" xmlns:gml="http://www.opengis.net/gml" xmlns:ogc="http://www.opengis.net/ogc" xmlns:wcs="http://www.opengis.net/wcs/1.1.1" xmlns:xlink="http://www.w3.org/1999/xlink" xsi:schemaLocation="http://www.opengis.net/wps/1.0.0 http://schemas.opengis.net/wps/1.0.0/wpsAll.xsd">
<ows:Identifier>gs:WeatherStream</ows:Identifier>
<wps:DataInputs>
<wps:Input>
<ows:Identifier>Longitude</ows:Identifier>
<wps:Data>
<wps:LiteralData>-114</wps:LiteralData>
</wps:Data>
</wps:Input>
<wps:Input>
<ows:Identifier>Latitude</ows:Identifier>
<wps:Data>
<wps:LiteralData>45</wps:LiteralData>
</wps:Data>
</wps:Input>
<wps:Input>
<ows:Identifier>English units</ows:Identifier>
<wps:Data>
<wps:LiteralData>true</wps:LiteralData>
</wps:Data>
</wps:Input>
<wps:Input>
<ows:Identifier>Archive</ows:Identifier>
<wps:Data>
<wps:LiteralData>all</wps:LiteralData>
</wps:Data>
</wps:Input>
<wps:Input>
<ows:Identifier>Start date</ows:Identifier>
<wps:Data>
<wps:LiteralData>2020-05-18</wps:LiteralData>
</wps:Data>
</wps:Input>
<wps:Input>
<ows:Identifier>End date</ows:Identifier>
<wps:Data>
<wps:LiteralData>2020-05-20 10:00:00</wps:LiteralData>
</wps:Data>
</wps:Input>
</wps:DataInputs>
<wps:ResponseForm>
<wps:RawDataOutput mimeType="application/octet-stream">
<ows:Identifier>output</ows:Identifier>
</wps:RawDataOutput>
</wps:ResponseForm>
</wps:Execute>
With the above example saved to a file (for example test.xml), the following POST request can be executed with curl:
curl -q -v -XPOST -H "Content-type: xml" -d @test.xml "http://aws.wfas.net/geoserver/wps?request=Execute&service=WPS&version=1.0.0">output.wxs
Example output: