Overview

This import is available in DELFT-FEWS versions after 25-11-2008

Imports time series data in NetCDF format from MATROOS Forecast databases. The import reader creaters a perl URL for direct data retrieving from Matroos. This NetCDF data import retrieves regulare and/or irregular grids from the MATROOS database. There are also three types of NOOS import functions in Delft FEWS to import scalar time series from MATROOS, see the NOOS import function for this type.

The import function for direct retrieval of grid data (maps) is matroos_netcdfmapseries.

More information on the retrieval of time series from Matroos can be found on: http://matroos.deltares.nl/direct/index.html

Configuring the Import

An example of the matroos_netcdfmapseries configuration will be given here. The reader is named matroos_netcdfmapseries which should be configured in the general section of the import. The general section must also contain the server URL and a correct username and password if you need to log-in. The relativeViewPeriod in the general section is used to select the period to retrieve data for.

An example import configuration is shown below:

ImportMatroosMap 1.00 default.xml
<?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">
  <import>
	<general>
		<importType>matroos_netcdfmapseries</importType>
		<serverUrl>http://matroos.deltares.nl</serverUrl>
		<user>dummy_username</user>
		<password>dummy_password</password>
		<relativeViewPeriod unit="hour" start="-1" end="12"/>
		<idMapId>IdImportMatroosMap</idMapId>
		<unitConversionsId>ImportUnitConversions</unitConversionsId>
		<importTimeZone>
			<timeZoneOffset>+00:00</timeZoneOffset>
		</importTimeZone>
		<dataFeedId>Matroos</dataFeedId>
        </general>
	<timeSeriesSet>
		<moduleInstanceId>ImportMatroos_Maps</moduleInstanceId>
		<valueType>grid</valueType>
		<parameterId>Snelheid.u.F0</parameterId>
		<locationId>hmcn_zeedelta</locationId>
		<timeSeriesType>external forecasting</timeSeriesType>
		<timeStep unit="minute" multiplier="30"/>
		<readWriteMode>add originals</readWriteMode>
		<synchLevel>6</synchLevel>
	</timeSeriesSet>
	<timeSeriesSet>
		<moduleInstanceId>ImportMatroos_Maps</moduleInstanceId>
		<valueType>grid</valueType>
		<parameterId>Snelheid.v.F0</parameterId>
		<locationId>hmcn_zeedelta</locationId>
		<timeSeriesType>external forecasting</timeSeriesType>
		<timeStep unit="minute" multiplier="30"/>
		<readWriteMode>add originals</readWriteMode>
		<synchLevel>6</synchLevel>
	</timeSeriesSet>
  </import>
</timeSeriesImportRun>

When a locationSet or multiple time series sets are configured in the import module instance, the Noos readers will construct URL's for each time series and retreive the data from the Matroos database sequentially. An improvement of the import readers could be to construct a more complex URL and retreive the data for multiple time series in one URL query.

The IdMapping configuration is very important because this maps the internal FEWS Id's to the Matroos Id's. In the IdMapping the following FEWS and Matroos elements are mapped:

  • the FEWS externalLocation is used to map the Matroos source element
  • the FEWS externalParameter is used to map the Matroos color element

The FEWS external qualifiers can be used to add extra information to the URL. In the example below the following information is stored in the external qualifiers. This information is used to resample the grid. MATROOS will interpolate theoriginal grid to the grid definition you give in the qualifiers.

  • the FEWS externalQualifier1 is used to map the Matroos coordsys element
  • the FEWS externalQualifier2 is used to map the Matroos xmin and xmax elements
  • the FEWS externalQualifier3 is used to map the Matroos ymin and ymax elements
  • the FEWS externalQualifier4 is used to map the Matroos xn and yn elements

An example of URL can be; http://matroos.deltares.nl/matroos/scripts/matroos.pl?
source=hmcn_zeedelta&color=velv&coordsys=RD&xmin=54000&xmax=67000
&ymin=442000&ymax=449000&xn=101&yn=101&from=200811250810&to=200811252110&timezone=gmt&format=nc

An example IdMapping file for the matroos_netcdfmapseries reader is shown below:

IdImportMatroosMap 1.00 default.xml
<?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 internalParameter="Snelheid.u.F0" internalLocation="hmcn_zeedelta" externalLocation="hmcn_zeedelta"
 externalParameter="velu" externalQualifier1="coordsys=RD" externalQualifier2="xmin=54000&amp;xmax=67000"
 externalQualifier3="ymin=442000&amp;ymax=449000" externalQualifier4="xn=101&amp;yn=101"/>
	<map internalParameter="Snelheid.v.F0" internalLocation="hmcn_zeedelta" externalLocation="hmcn_zeedelta"
 externalParameter="velv" externalQualifier1="coordsys=RD" externalQualifier2="xmin=54000&amp;xmax=67000"
 externalQualifier3="ymin=442000&amp;ymax=449000" externalQualifier4="xn=101&amp;yn=101"/>
</idMap>

When importing grids in the FEWS database it is required to configure the grid characteristics in the grids.XML file. The grid characteristics must be similar to the grids imported from MATROOS.

Grids 1.00 default.xml
	<regular locationId="hmcn_zeedelta">
		<description>HMCN Zeedelta Model</description>
		<rows>101</rows>
		<columns>101</columns>
		<geoDatum>Rijks Driehoekstelsel</geoDatum>
		<firstCellCenter>
			<x>54000</x>
			<y>449000</y>
		</firstCellCenter>
		<xCellSize>130</xCellSize>
		<yCellSize>70</yCellSize>
	</regular>

NetCDF format

The NetCDF format used can be found on the MATROOS webpage and the FEWS-PI pages.

  • No labels