8 #ifndef OOPS_GENERIC_PSEUDOMODEL_H_
9 #define OOPS_GENERIC_PSEUDOMODEL_H_
18 #include "oops/util/Duration.h"
19 #include "oops/util/Logger.h"
28 template <
typename MODEL>
35 static const std::string
classname() {
return "oops::PseudoModel";}
53 void print(std::ostream &)
const override;
56 std::vector<eckit::LocalConfiguration>
confs_;
62 template<
typename MODEL>
64 : tstep_(
util::Duration(conf.getString(
"tstep"))), vars_(conf,
"state variables"),
65 confs_(conf.getSubConfigurations(
"states")),
67 Log::trace() <<
"PseudoModel<MODEL>::PseudoModel done" << std::endl;
72 template<
typename MODEL>
75 Log::trace() <<
"PseudoModel<MODEL>::initialize done" << std::endl;
80 template<
typename MODEL>
82 Log::trace() <<
"PseudoModel<MODEL>:step Starting " << std::endl;
84 xx.
read(confs_[currentstate_++]);
85 Log::trace() <<
"PseudoModel<MODEL>::step done" << std::endl;
90 template<
typename MODEL>
92 Log::trace() <<
"PseudoModel<MODEL>::finalize done" << std::endl;
97 template<
typename MODEL>
99 os <<
"Pseudo model reading states from files with " << tstep_ <<
" time resolution";
Geometry class used in oops; subclass of interface class interface::Geometry.
Auxiliary state related to model (could be e.g. model bias), not used at the moment.
Base class for generic implementations of the forecasting models. Use this class as a base class for ...
Generic implementation of the pseudo model (steps through time by reading states)
const oops::Variables vars_
void step(State_ &, const ModelAux_ &) const override
one forecast step
std::vector< eckit::LocalConfiguration > confs_
static const std::string classname()
PseudoModel(const Geometry_ &, const eckit::Configuration &)
ModelAuxControl< MODEL > ModelAux_
Geometry< MODEL > Geometry_
void initialize(State_ &) const override
initialize forecast
const oops::Variables & variables() const override
model variables
const util::Duration tstep_
const util::Duration & timeResolution() const override
model time step
void finalize(State_ &) const override
finalize forecast
void print(std::ostream &) const override
Print; used for logging.
State class used in oops; subclass of interface class interface::State.
void updateTime(const util::Duration &dt)
Update this State's valid time by dt.
void read(const eckit::Configuration &)
Read this State from file.
The namespace for the main oops code.