Classes | |
struct | HandleDeleter |
struct | IndexDeleter |
Typedefs | |
using | MeteoParam = MeteoData::Parameters |
using | CodesHandlePtr = std::unique_ptr< codes_handle, HandleDeleter > |
using | CodesIndexPtr = std::unique_ptr< codes_index, IndexDeleter > |
Functions | |
static long | getDescriptor (const std::string &key) |
static std::vector< long > | getDescriptors (std::vector< std::string > keys) |
CodesHandlePtr | makeUnique (codes_handle *h) |
CodesIndexPtr | makeUnique (codes_index *i) |
CodesIndexPtr | indexFile (const std::string &filename, const std::vector< std::string > &index_keys, bool verbose) |
bool | getParameter (CodesHandlePtr &h, const std::string ¶meterName, double ¶meterValue, const IOUtils::ThrowOptions &throwError) |
bool | getParameter (CodesHandlePtr &h, const std::string ¶meterName, long ¶meterValue, const IOUtils::ThrowOptions &throwError) |
bool | getParameter (CodesHandlePtr &h, const std::string ¶meterName, int ¶meterValue, const IOUtils::ThrowOptions &throwError) |
bool | getParameter (CodesHandlePtr &h, const std::string ¶meterName, std::string ¶meterValue, const IOUtils::ThrowOptions &throwError) |
std::vector< CodesHandlePtr > | getMessages (const std::string &filename, ProductKind product) |
std::vector< CodesHandlePtr > | getMessages (FILE *in_file, ProductKind product) |
Date | getMessageDateGrib (CodesHandlePtr &h, const double &tz_in) |
std::map< std::string, double > | getGridParameters (CodesHandlePtr &h_unique) |
std::map< std::string, double > | getGriddedValues (CodesHandlePtr &h, std::vector< double > &values) |
void | getGriddedValues (CodesHandlePtr &h, std::vector< double > &values, std::map< std::string, double > &gridParams) |
void | getNearestValues_grib (CodesHandlePtr &h, const std::vector< double > &in_lats, const std::vector< double > &in_lons, std::vector< double > &out_lats, std::vector< double > &out_lons, std::vector< double > &distances, std::vector< double > &values, std::vector< int > &indexes) |
void | unpackMessage (CodesHandlePtr &m) |
std::string | getSubsetPrefix (const size_t &subsetNumber) |
Date | getMessageDateBUFR (CodesHandlePtr &h, const size_t &subsetNumber, const double &tz_in) |
void | setMissingValue (CodesHandlePtr &message, double missingValue) |
bool | selectParameter (codes_index *raw, const std::string ¶m_key, const std::string ¶mId) |
bool | selectParameter (codes_index *raw, const std::string ¶m_key, const double ¶mId) |
bool | selectParameter (codes_index *raw, const std::string ¶m_key, const long ¶mId) |
void | writeToFile (CodesHandlePtr &h, const std::string &filename) |
static void | setHeader (codes_handle *ibufr, long num_subsets) |
static void | addDescriptors (std::vector< long > &descriptors, const std::vector< long > &to_add) |
static void | addRepeatedDescriptors (std::vector< long > &descriptors, std::vector< long > &replication_factors_in_subset, const std::vector< long > &repeated_descriptors, long num) |
static void | addStandardDescriptors (std::vector< long > &descriptors, long num, const std::set< std::string > &available_params, const std::string ¶m, long descriptor) |
static void | setCryosDescriptors (std::vector< long > &descriptors, std::vector< long > &replication_factors_in_subset, long num_heights) |
static void | setMeteoIODesrciptors (std::vector< long > &descriptors, std::vector< long > &replication_factors_in_subset, const std::map< MeteoParam, size_t > &multi_param_occurences, const std::set< std::string > &available_params, const std::vector< MeteoParam > &POSSIBLE_MULTIPLE_PARAMETERS) |
static void | setReplicationFactors (codes_handle *ibufr, const std::vector< long > &replication_factors_in_subset, long num_subsets) |
CodesHandlePtr | createBUFRMessageFromSample (long num_subsets, const std::map< MeteoParam, size_t > &multi_param_occurences, const std::set< std::string > &available_params, const std::vector< MeteoParam > &POSSIBLE_MULTIPLE_PARAMETERS, const bool &write_cryos_station, const long &num_cryo_heights) |
void | setTime (CodesHandlePtr &ibufr, const Date &date, const std::string &subset_prefix) |
void | setTypicalTime (CodesHandlePtr &ibufr, const Date &date) |
bool | setParameter (CodesHandlePtr &ibufr, const std::string ¶meterName, const double ¶meterValue) |
bool | setParameter (CodesHandlePtr &ibufr, const std::string ¶meterName, const long ¶meterValue) |
bool | setParameter (CodesHandlePtr &ibufr, const std::string ¶meterName, const std::vector< long > ¶meterValues) |
bool | setParameter (CodesHandlePtr &ibufr, const std::string ¶meterName, const std::string ¶meterValue) |
void | packMessage (CodesHandlePtr &m) |
template<typename T > | |
std::vector< CodesHandlePtr > | getMessages (CodesIndexPtr &index, const std::string ¶m_key, const T ¶mID, const std::string &level_key, const std::string &levelType) |
template<typename T > | |
bool | getParameter (CodesHandlePtr &h, const std::vector< std::string > ¶mNames, T ¶m_value, const size_t &subset_number=-1) |
Variables | |
const int | WMO_BUFR_TABLE_NO = 41 |
const std::string | BUFR_HEIGHT_KEY = "height" |
const std::map< std::string, std::string > | BUFR_PARAMETER |
const std::map< std::string, std::string > | BUFR_PARAMETER_ALT {{"TA", "airTemperatureAt2m"}} |
const std::vector< int > | FLAG_TO_EPSG = {4326, 4258, 4269, 4314} |
const long | SNOW_SURFACE_QUALIFIER = 6 |
static const std::map< std::string, long > | BUFR_DESCRIPTORS |
const long | NOPARAMID = -1 |
const std::map< std::string, long > | GRIB_DEFAULT_PARAM_TABLE |
const std::map< std::string, std::string > | GRIB_DEFAULT_LEVELTYPE_TABLE |
const std::map< std::string, long > | GRIB_DEFAULT_LEVELNO_TABLE |
using mio::codes::CodesHandlePtr = typedef std::unique_ptr<codes_handle, HandleDeleter> |
using mio::codes::CodesIndexPtr = typedef std::unique_ptr<codes_index, IndexDeleter> |
using mio::codes::MeteoParam = typedef MeteoData::Parameters |
|
static |
|
static |
|
static |
CodesHandlePtr mio::codes::createBUFRMessageFromSample | ( | long | num_subsets, |
const std::map< MeteoParam, size_t > & | multi_param_occurences, | ||
const std::set< std::string > & | available_params, | ||
const std::vector< MeteoParam > & | POSSIBLE_MULTIPLE_PARAMETERS, | ||
const bool & | write_cryos_station, | ||
const long & | num_cryo_heights | ||
) |
|
static |
|
static |
std::map< std::string, double > mio::codes::getGriddedValues | ( | CodesHandlePtr & | h, |
std::vector< double > & | values | ||
) |
void mio::codes::getGriddedValues | ( | CodesHandlePtr & | h, |
std::vector< double > & | values, | ||
std::map< std::string, double > & | gridParams | ||
) |
std::map< std::string, double > mio::codes::getGridParameters | ( | CodesHandlePtr & | h_unique | ) |
Date mio::codes::getMessageDateBUFR | ( | CodesHandlePtr & | h, |
const size_t & | subsetNumber, | ||
const double & | tz_in | ||
) |
Date mio::codes::getMessageDateGrib | ( | CodesHandlePtr & | h, |
const double & | tz_in | ||
) |
std::vector< CodesHandlePtr > mio::codes::getMessages | ( | CodesIndexPtr & | index, |
const std::string & | param_key, | ||
const T & | paramID, | ||
const std::string & | level_key, | ||
const std::string & | levelType | ||
) |
std::vector< CodesHandlePtr > mio::codes::getMessages | ( | const std::string & | filename, |
ProductKind | product | ||
) |
std::vector< CodesHandlePtr > mio::codes::getMessages | ( | FILE * | in_file, |
ProductKind | product | ||
) |
void mio::codes::getNearestValues_grib | ( | CodesHandlePtr & | h, |
const std::vector< double > & | in_lats, | ||
const std::vector< double > & | in_lons, | ||
std::vector< double > & | out_lats, | ||
std::vector< double > & | out_lons, | ||
std::vector< double > & | distances, | ||
std::vector< double > & | values, | ||
std::vector< int > & | indexes | ||
) |
bool mio::codes::getParameter | ( | CodesHandlePtr & | h, |
const std::string & | parameterName, | ||
double & | parameterValue, | ||
const IOUtils::ThrowOptions & | throwError | ||
) |
bool mio::codes::getParameter | ( | CodesHandlePtr & | h, |
const std::string & | parameterName, | ||
int & | parameterValue, | ||
const IOUtils::ThrowOptions & | throwError | ||
) |
bool mio::codes::getParameter | ( | CodesHandlePtr & | h, |
const std::string & | parameterName, | ||
long & | parameterValue, | ||
const IOUtils::ThrowOptions & | throwError | ||
) |
bool mio::codes::getParameter | ( | CodesHandlePtr & | h, |
const std::string & | parameterName, | ||
std::string & | parameterValue, | ||
const IOUtils::ThrowOptions & | throwError | ||
) |
bool mio::codes::getParameter | ( | CodesHandlePtr & | h, |
const std::vector< std::string > & | paramNames, | ||
T & | param_value, | ||
const size_t & | subset_number = -1 |
||
) |
std::string mio::codes::getSubsetPrefix | ( | const size_t & | subsetNumber | ) |
Returns either an empty string or a prefix to index the subset in BUFR messages. As /subsetNumber=id/ where a key can follow. If no subset is present, an empty string is returned.
subsetNumber | The subset number. |
CodesIndexPtr mio::codes::indexFile | ( | const std::string & | filename, |
const std::vector< std::string > & | index_keys, | ||
bool | verbose | ||
) |
CodesHandlePtr mio::codes::makeUnique | ( | codes_handle * | h | ) |
CodesIndexPtr mio::codes::makeUnique | ( | codes_index * | i | ) |
void mio::codes::packMessage | ( | CodesHandlePtr & | m | ) |
bool mio::codes::selectParameter | ( | codes_index * | raw, |
const std::string & | param_key, | ||
const double & | paramId | ||
) |
bool mio::codes::selectParameter | ( | codes_index * | raw, |
const std::string & | param_key, | ||
const long & | paramId | ||
) |
bool mio::codes::selectParameter | ( | codes_index * | raw, |
const std::string & | param_key, | ||
const std::string & | paramId | ||
) |
|
static |
|
static |
|
static |
void mio::codes::setMissingValue | ( | CodesHandlePtr & | message, |
double | missingValue | ||
) |
bool mio::codes::setParameter | ( | CodesHandlePtr & | ibufr, |
const std::string & | parameterName, | ||
const double & | parameterValue | ||
) |
bool mio::codes::setParameter | ( | CodesHandlePtr & | ibufr, |
const std::string & | parameterName, | ||
const long & | parameterValue | ||
) |
bool mio::codes::setParameter | ( | CodesHandlePtr & | ibufr, |
const std::string & | parameterName, | ||
const std::string & | parameterValue | ||
) |
bool mio::codes::setParameter | ( | CodesHandlePtr & | ibufr, |
const std::string & | parameterName, | ||
const std::vector< long > & | parameterValues | ||
) |
|
static |
void mio::codes::setTime | ( | CodesHandlePtr & | ibufr, |
const Date & | date, | ||
const std::string & | subset_prefix | ||
) |
void mio::codes::setTypicalTime | ( | CodesHandlePtr & | ibufr, |
const Date & | date | ||
) |
void mio::codes::unpackMessage | ( | CodesHandlePtr & | m | ) |
void mio::codes::writeToFile | ( | CodesHandlePtr & | h, |
const std::string & | filename | ||
) |
|
static |
const std::string mio::codes::BUFR_HEIGHT_KEY = "height" |
const std::map< std::string, std::string > mio::codes::BUFR_PARAMETER |
const std::map< std::string, std::string > mio::codes::BUFR_PARAMETER_ALT {{"TA", "airTemperatureAt2m"}} |
const std::vector< int > mio::codes::FLAG_TO_EPSG = {4326, 4258, 4269, 4314} |
const std::map< std::string, long > mio::codes::GRIB_DEFAULT_LEVELNO_TABLE |
const std::map< std::string, std::string > mio::codes::GRIB_DEFAULT_LEVELTYPE_TABLE |
const std::map< std::string, long > mio::codes::GRIB_DEFAULT_PARAM_TABLE |
const long mio::codes::NOPARAMID = -1 |
const long mio::codes::SNOW_SURFACE_QUALIFIER = 6 |
const int mio::codes::WMO_BUFR_TABLE_NO = 41 |