Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

scrollbar


Excerpt
hiddentrue

Sets Dynamically determines the forecast length or the start time of the run based on timeseries input


Function:

Sets the forecast length or the start of the run


Module Name:

ForecastLengthEstimator

Where to Use?

In a workflow

Why to Use?

To set the length of a forecast or the start of the forecast based on (external) timeseries.

Description:

The forecastLengthEstimator is a module that can be used at the start of a workflow the set the length of the operations in the other modules in that workflow.

Preconditions:

the endoverrulable attribute in the relative view period in the time series sets must be set to true in all modules you want to apply the forecast length to

Outcome(s):

 

Scheendump(s):

link to attached screendump(s) for displays only

Remark(s):

 

Available since:

DelftFEWS200803

...

Code Block
xml
xml
<?xml version="1.0" encoding="UTF-8"?>
<forecastLengthEstimator 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/forecastLengthEstimator.xsd">
	<externalHistoricalTimeSeries>
		<moduleInstanceId>test</moduleInstanceId>
		<valueType>scalar</valueType>
		<parameterId>par</parameterId>
		<locationId>loc</locationId>
		<timeSeriesType>external historical</timeSeriesType>
		<timeStep unit="hour"/>
		<relativeViewPeriod unit="hour" start="-5" end="0"/>
		<readWriteMode>read only</readWriteMode>
	</externalHistoricalTimeSeries>
	<setTime0ToLatestNonMissing>true</setTime0ToLatestNonMissing>
</forecastLengthEstimator>

findLatestCommonExternalForecastTime

When your forecast depends on multiple external forecasts (e.g. of an NWP forecast and a Hydro forecast) you may want to harmonize that external forecast time. This can be done by identifying the common external forecast time in the ForecastLengthEstimator and using that as a identifier in the timeseriesset used in the workflow. 

Code Block
titleForecastlengthEstimator
<?xml version="1.0" encoding="UTF-8"?>
<forecastLengthEstimator 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/forecastLengthEstimator.xsd">
	<findLatestCommonExternalForecastTime externalForecastTimeId="test">
		<eventCodeOnChange>forecast.newReference</eventCodeOnChange>
		<dataFeed id="dataFeed1">
			<timeSeriesSet>
				<moduleInstanceId>test1</moduleInstanceId>
				<valueType>scalar</valueType>
				<parameterId>par</parameterId>
				<locationId>loc</locationId>
				<timeSeriesType>external forecasting</timeSeriesType>
				<timeStep unit="hour"/>
				<readWriteMode>read only</readWriteMode>
			</timeSeriesSet>
		</dataFeed>
		<dataFeed id="dataFeed2">
			<timeSeriesSet>
				<moduleInstanceId>test2</moduleInstanceId>
				<valueType>scalar</valueType>
				<parameterId>par</parameterId>
				<locationId>loc</locationId>
				<timeSeriesType>external forecasting</timeSeriesType>
				<timeStep unit="hour"/>
				<readWriteMode>read only</readWriteMode>
			</timeSeriesSet>
		</dataFeed>
	</findLatestCommonExternalForecastTime>
</forecastLengthEstimator>


Code Block
titleTimeseries usage in workflow (after ForecastLengthEstimator)
<timeSeriesSet>
	<moduleInstanceId>ImportTMSI</moduleInstanceId>
	<valueType>scalar</valueType>
	<parameterId>P</parameterId>
	<locationId>Rain93</locationId>
	<timeSeriesType>external forecasting</timeSeriesType>
	<timeStep unit="minute" multiplier="10"/>
	<externalForecastTimeId>test</externalForecastTimeId>
	<readWriteMode>read complete forecast</readWriteMode>
</timeSeriesSet>


Code Block
titleUsage in TimeSeriesExport
<general>	
	<exportType>PI 1.5</exportType>
	<folder>../junit_test_output/nl/wldelft/fews/system/plugin/dataExport/TimeSeriesExportTest/exportPiExternalForecastTimeId/export</folder>
	<exportFileName>
		<name>rainfallPiExternalForecastTimeId.xml</name>
	</exportFileName>
	<idMapId>Telemetry</idMapId>
	<unitConversionsId>UnitConversions</unitConversionsId>
	<flagConversionsId>FlagConversions</flagConversionsId>
	<exportMissingValueString>-999.0</exportMissingValueString>
	<externalForecastTimeId>test</externalForecastTimeId>
</general>	


Sample input and output

Sample input and output

...