NASA Logo
Ocean Color Science Software

ocssw V2022
expand3D.hpp File Reference
#include <iostream>
#include <unordered_map>
#include <unordered_set>
#include <vector>
#include <string>
#include <boost/algorithm/string.hpp>
#include <netcdf>
#include "genutils.h"
#include "readL2scan.h"
#include <boost/lexical_cast.hpp>
Include dependency graph for expand3D.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define EXIT_LOG(...)
 

Functions

void set_mapper (const std::string &input_file_name, std::string &products_requested, std::vector< std::string > &products_requested_separated, const std::string &requested_wavelengths)
 
void set_prodname_3d_to_l2 (const std::vector< std::string > &prodparam, l2_prod &l2_str, std::vector< std::string > &l2_prodname, std::vector< std::string > &l3_prodname, std::vector< int32_t > &thirdDimId, std::vector< float > &min_value, std::vector< float > &max_value)
 
bool set_l2_flags_use (const std::string &flagsuse)
 
void parse_wv_list (const std::string &wv_list, const std::unordered_map< int, int > &wv3d_list, std::vector< int > &wv_requested_vals, std::vector< int > &wv_requested_indexes, bool exit_on_not_found=true)
 
float l3_attr (const std::string &inp3)
 

Macro Definition Documentation

◆ EXIT_LOG

#define EXIT_LOG (   ...)
Value:
{ \
__VA_ARGS__; \
std::cerr << "Exiting. See " << __FILE__ << ":" << __LINE__ << std::endl; \
exit(EXIT_FAILURE); \
}

Definition at line 14 of file expand3D.hpp.

Function Documentation

◆ l3_attr()

float l3_attr ( const std::string inp3)

Definition at line 421 of file expand3D.cpp.

◆ parse_wv_list()

void parse_wv_list ( const std::string wv_list,
const std::unordered_map< int, int > &  wv3d_list,
std::vector< int > &  wv_requested_vals,
std::vector< int > &  wv_requested_indexes,
bool  exit_on_not_found 
)
Parameters
wv_listuser supplied wv3d list
wv3d_listwavelength and their indexes;
wv_requested_valsuser requested wavelength list
wv_requested_indexesslices indexes of the 3D variable
exit_on_not_foundhard exit if wavelength not found

Definition at line 70 of file expand3D.cpp.

◆ set_l2_flags_use()

bool set_l2_flags_use ( const std::string flagsuse)

Definition at line 407 of file expand3D.cpp.

◆ set_mapper()

void set_mapper ( const std::string input_file_name,
std::string products_requested,
std::vector< std::string > &  products_requested_separated,
const std::string requested_wavelengths 
)

readL2, openL2 uses the maps from this module. If the module is not initialized, the function read and process an unexpanded L2 products

Parameters
input_file_namepath to nc file
products_requestedproducts requested by the user, with delimiters
products_requested_separatedlist of the separated products
requested_wavelengthslist of requested wavelength

Definition at line 235 of file expand3D.cpp.

◆ set_prodname_3d_to_l2()

void set_prodname_3d_to_l2 ( const std::vector< std::string > &  prodparam,
l2_prod &  l2_str,
std::vector< std::string > &  l2_prodname,
std::vector< std::string > &  l3_prodname,
std::vector< int32_t > &  thirdDimId,
std::vector< float > &  min_value,
std::vector< float > &  max_value 
)

Definition at line 383 of file expand3D.cpp.