Interface class for the generator models.
These models generate data for a specific parameter when all other options failed (the resampling could not help). Therefore, there is nothing more that could be done with the temporal history of the data, we have to use a totally different approach: either generic data (constant value, etc) or generate the data from other meteorological parameters (relying on a parametrization, like clear sky for ILWR).
#include <GeneratorAlgorithms.h>
Public Member Functions | |
virtual | ~GeneratorAlgorithm () |
virtual bool | generate (const size_t ¶m, MeteoData &md, const std::vector< MeteoData > &vecMeteo)=0 |
virtual bool | create (const size_t ¶m, const size_t &ii_min, const size_t &ii_max, std::vector< MeteoData > &vecMeteo)=0 |
Fill one time series of MeteoData for one station. More... | |
bool | skipStation (const std::string &station_id) const |
Should this station be skipped, based on user-provided station ID restrictions? More... | |
bool | skipTimeStep (const Date &dt) const |
Should this timestep be skipped, based on user-provided time restrictions? More... | |
std::vector< DateRange > | getTimeRestrictions () const |
std::string | getAlgo () const |
Protected Member Functions | |
GeneratorAlgorithm (const std::vector< std::pair< std::string, std::string > > &vecArgs, const std::string &i_algo, const std::string &i_section, const double &TZ) | |
protected constructor only to be called by children More... | |
virtual void | parse_args (const std::vector< std::pair< std::string, std::string > > &) |
Static Protected Member Functions | |
static std::set< std::string > | initStationSet (const std::vector< std::pair< std::string, std::string > > &vecArgs, const std::string &keyword) |
Protected Attributes | |
const std::vector< DateRange > | time_restrictions |
const std::set< std::string > | excluded_stations |
const std::set< std::string > | kept_stations |
const std::string | algo |
const std::string | section |
Static Protected Attributes | |
static const double | soil_albedo = .23 |
static const double | snow_albedo = .85 |
static const double | snow_thresh = .1 |
|
inlinevirtual |
|
protected |
protected constructor only to be called by children
|
pure virtual |
Fill one time series of MeteoData for one station.
This is used by the dataCreators to create a new parameter in one go for the whole timeseries.
[in] | param | meteo parameter to generate |
[in] | ii_min | minimum index to apply it to in vecMeteo |
[in] | ii_max | maximum index to apply it to in vecMeteo |
[in] | vecMeteo | meteo timeseries to process |
Implemented in mio::AllSkyLWGenerator, mio::AllSkySWGenerator, mio::ClearSkyLWGenerator, mio::ClearSkySWGenerator, mio::ConstGenerator, mio::ESOLIPGenerator, mio::HumidityGenerator, mio::IswrAlbedoGenerator, mio::MeteoIndex, mio::PrecSplitting, mio::RadiationComponents, mio::SinGenerator, mio::StandardPressureGenerator, mio::TauCLDGenerator, mio::TsGenerator, and mio::WindComponents.
|
pure virtual |
Implemented in mio::AllSkyLWGenerator, mio::AllSkySWGenerator, mio::ClearSkyLWGenerator, mio::ClearSkySWGenerator, mio::ConstGenerator, mio::ESOLIPGenerator, mio::HumidityGenerator, mio::IswrAlbedoGenerator, mio::MeteoIndex, mio::PrecSplitting, mio::RadiationComponents, mio::SinGenerator, mio::StandardPressureGenerator, mio::TauCLDGenerator, mio::TsGenerator, and mio::WindComponents.
|
inline |
|
inline |
|
staticprotected |
|
inlineprotectedvirtual |
bool mio::GeneratorAlgorithm::skipStation | ( | const std::string & | station_id | ) | const |
Should this station be skipped, based on user-provided station ID restrictions?
[in] | station_id | ID of the current station |
bool mio::GeneratorAlgorithm::skipTimeStep | ( | const Date & | dt | ) | const |
Should this timestep be skipped, based on user-provided time restrictions?
[in] | dt | current timestep |
|
protected |
|
protected |
|
protected |
|
protected |
|
staticprotected |
|
staticprotected |
|
staticprotected |
|
protected |