Versions Compared

Key

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

...

No Format
<serverUrl>http://nomads.ncep.noaa.gov:9090/dods/gfs/gfs%RELATIVE_TIME_IN_SECONDS(yyyyMMdd, -18000 )%/gfs_%RELATIVE_TIME_IN_SECONDS(HH,-18000)%z</serverUrl>
fileNameDateTimeFilter

One can filter the reading of files and subdirectories by explicity defining which files and (sub)folders are to be read. This can be done using date-strings in the names to be able to read data from a folder setup like "data\2022\01\10\*.*" which in this example lists the year, month and day. This is very useful to read data from large datasets where only the most recent data is to be read. Note that zip files are always internally handled as if it were a folder. The relativeViewperiod defines in which folders FEWS will actively and only look for available data files.
Note that the subFolderLevel of 0 can be used for defining a file filter. The counting of real folders starts from 1 onwards.

The below example reads only the latest files from a server where many files are stored. In this example these are zipfiles provided at a 6-hour timestep. 

Code Block
languagexml
linenumberstrue
<fileNameDateTimeFilter subFolderLevel="1">
	<timeStep unit="hour" multiplier="6"/>
	<dateTimePattern>'hr44_'yyyyMMddHH'.zip'</dateTimePattern>
	<preFixLength>5</preFixLength>
	<postFixLength>4</postFixLength>
</fileNameDateTimeFilter>
<relativeViewPeriod unit="hour" start="-5" end="0"/>


Another example is where data is to be read from a folder structure like "data\<year>\<month>\<day>\*.*"
In this example FEWS will read the data for the given relativeViewPeriod of the last 10 days only.

Code Block
languagexml
linenumberstrue
<folder>data</folder>
<fileNameDateTimeFilter subFolderLevel="1">
	<timeStep unit="year" multiplier="1"/>
	<dateTimePattern>yyyy</dateTimePattern>
	<preFixLength>0</preFixLength>
	<postFixLength>0</postFixLength>
</fileNameDateTimeFilter>
<fileNameDateTimeFilter subFolderLevel="2">
	<timeStep unit="month" multiplier="1"/>
	<dateTimePattern>MM</dateTimePattern>
	<preFixLength>0</preFixLength>
	<postFixLength>0</postFixLength>
</fileNameDateTimeFilter>
<fileNameDateTimeFilter subFolderLevel="3">
	<timeStep unit="day" multiplier="1"/>
	<dateTimePattern>dd</dateTimePattern>
	<preFixLength>0</preFixLength>
	<postFixLength>0</postFixLength>
</fileNameDateTimeFilter>
<relativeViewPeriod unit="day" start="-10" end="0"/>
ftpPassiveMode

When using "ftp://" import the option of passive mode is supported.  This is an optinal field, default value is false, and can be configured in the general section.

...

eg: <fileNamePatternFilter>%TIME_ZERO(yyyy)%??????.nc</fileNamePatternFilter>?????.nc</fileNamePatternFilter>

Note that the filter does not apply to any zip file directly, but only to the files that are within the zip file.

fileNameObservationDateTimePattern

...

User name, required when importing from protected database connections or protected servers. The username/password is not used for accessing ftp folders. There the credentials have to be defined in the ftp address like ftp://<user>:<password>@ftp.addres.com

password, encryptedPassword

Password, required when importing from protected database connections or protected servers. Please use the Hex value for special characters (e.g. a @ must be specified as %40)
It is strongly recommend to using encryptedPassword, although the encryption within FEWS is relatively limited. Encrypting your password can be done by the "F12 →  S - clipboard → encrypt password" debug menu option.

relativeViewPeriod

The relative period for which data should be imported. This period is relative to the time 0 of the run. When the start and end time are overrulable the user can specify the download length with the cold state time and forecast length in the manual forecast dialog. It is also possible to import data for an absolute period of time using the startDateTime and endDateTime elements.

...