pylag.gotm_data_reader module
Data reader for input data generated by GOTM.
Note
gotm_data_reader is implemented in Cython. Only a small portion of the API is exposed in Python with accompanying documentation. However, more details can be found in pylag.data_reader, where a set of python wrappers have been implemented.
- class pylag.gotm_data_reader.GOTMDataReader(config, mediator)
Bases:
DataReaderDataReader for GOTM
Objects of type GOTMDataReader are intended to manage all access to GOTM data objects, including data describing the model grid as well as model output variables.
GOTMDataReader employs linear interpolation in time. For interpolation in space, GOTM uses a dedicated Interpolator. The choice of 1D interpolator is made at run time.
- Parameters:
config (ConfigParser) – Configuration object.
mediator (Mediator) – Mediator object for managing access to data read from file.
See also
pylag.interpolationSupported interpolators.
- get_xmin(self) DTYPE_FLOAT_t
- get_ymin(self) DTYPE_FLOAT_t
- read_data(self, DTYPE_FLOAT_t time)
Read in time dependent variable data from file?
time is used to test if new data should be read in from file. If this is the case arrays containing time-dependent variable data are updated. Following this, all time interpolated gridded fields are computed.
- Parameters:
time (float) – The current time.
- setup_data_access(self, start_datetime, end_datetime)
Set up access to time-dependent variables.
- Parameters:
start_datetime (Datetime) – Datetime object corresponding to the simulation start time.
end_datetime (Datetime) – Datetime object corresponding to the simulation end time.