This is an import for time series published using the TAHMO API. 

FEWS configuration

In order to activate the TAHMO import as a FEWS import, it is required to set up a TimeSeriesImportRun module configuration file and an accompanying IdMap file.

The TAHMO import will take the serverUrl and append it with "stations" to obtain information about the available locations. It will then use the location id's to construct the query url's for the timeseries as such: "<serverUrl>/timeseries/<locationId>/hourly?startDate=...&endDate=...". 

Example Import configuration file:

<?xml version="1.0" encoding="UTF-8"?>
<timeSeriesImportRun xmlns="http://www.wldelft.nl/fews"
 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
 xsi:schemaLocation="http://www.wldelft.nl/fews http://fews.wldelft.nl/schemas/version1.0/timeSeriesImportRun.xsd">
<!-- This is an example import configuration file for importing Observations and Measurements data from a service -->
<import>
    <general>
        <importType>TAHMO</importType>
        <serverUrl>https://tahmoapi.host.net/v1/</serverUrl>
		<user>dummy_username</user>
        <password>dummy_password</password>
        <relativeViewPeriod unit="hour" start="-5" end="0" startOverrulable="true" endOverrulable="true"/>
        <idMapId>IdImportTahmo</idMapId>
    </general>
    <timeSeriesSet>
       <moduleInstanceId>ImportTahmo</moduleInstanceId>
       <valueType>scalar</valueType>
       <parameterId>MyPar</parameterId>
       <locationSetId>MyLocSet</locationSetId>
       <timeSeriesType>external historical</timeSeriesType>
       <timeStep unit="nonequidistant"/>
       <readWriteMode>add originals</readWriteMode>
       <synchLevel>1</synchLevel>
    </timeSeriesSet>
</import>
</timeSeriesImportRun>

Example IdMap file:

<?xml version="1.0" encoding="UTF-8"?>
<idMap version="1.1" xmlns="http://www.wldelft.nl/fews" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.wldelft.nl/fews http://fews.wldelft.nl/schemas/version1.0/idMap.xsd">
 <!--
    map internal timeseries directly to external timeseries
    externalLocation should be set to the location id
    externalParameter should be set to the parameter name
 -->
 
<map internalLocation="MyLoc1" internalParameter="MyPar1" externalLocation="TA00269" externalParameter="atmosphericPressure" />
<map internalLocation="MyLoc2" internalParameter="MyPar1" externalLocation="TA00099" externalParameter="windspeed" />
 
</idMap>

Quality flags

Quality flags are read from the TAHMO data and imported in FEWS as follow:

  • if the quality  flag is 1 or 2, it means that the value is good or inconsistent, which in FEWS will show as Original/Reliable (0)
  • if the quality  flag is 3, it means that the values is doubtful, which in FEWS will show as Original/Doubtful (3)
  • if the quality  flag is 4, it means that the values is erroneous, which in FEWS will show as Original/Unreliable (6)

Note that the quality flag 2 differs from quality flag 1 because it is a spatial homogeneity check, which can be done post import in FEWS. The quality flag 2 (inconsistent) can be produced by our spatial quality control. It is always done on at least a full day of data and indicates that the daily precipitation total for that day deviates from its nearby neighbours while models based on historical data would expect a higher correlation.

  • No labels