Public Member Functions | |
SatelliteFileData (const string &name, const string &mode) | |
virtual | ~SatelliteFileData () |
Destructor. | |
virtual const bool | contain_data (const float &lat, const float &lon, const double &time, const double &tolerance)=0 |
virtual const bool | contain_location (const float &lat, const float &lon, const double &tolerance)=0 |
check if this file has eventually data coincident with (lat,lon) Actually, it only tests if (lat,lon) is contained in the data's bounding rectangle. | |
virtual const bool | get_index (const float &lat, const float &lon, int &nearest_pix_idx, const float colocation_tolerance)=0 |
find the index of the nearest point to (lat,lon) in the data. If (lat,lon) is not found or out of the colocalisation_frame, returned indexes are [-1,-1] | |
virtual void | get_vindex (vector< vector< int > > &v_index, const float &lat, const float &lon, const float colocation_tolerance)=0 |
build the list of indices of pixels that are in colocation tolerance, sorted by increasing distance to (lat,lon) If (lat,lon) is not found or out of the colocalisation_frame, returns an empty vector | |
virtual const float | get_nearest_point_distance (const float &lat, const float &lon, const float coloc_tolerance)=0 |
virtual void | load_geolocation_data ()=0 |
read the geolocation data and put it in memory. This method is used to make the search of the indexes of a (lat,lon,time) point faster. | |
virtual void | free_geolocation_data () |
free eventually loaded geolocation data | |
virtual const bool | is_geolocation_data_loaded () const |
Tell if the geolocation data have been already loaded. | |
virtual void | close_data_file ()=0 |
closes the file. | |
virtual void | open_data_file ()=0 |
opens the file. | |
virtual void | load_v_pixel ()=0 |
load the list data pixels | |
virtual void | free_v_pixel () |
free the list data pixels | |
virtual const vector< PixelType > & | get_v_pixel () const |
accessor to the list of data pixels | |
virtual void | get_pixel_coord (const vector< int > &ipix, float &lat, float &lon, double &time)=0 |
retrieve the coordinates of a pixel using its index | |
float * | get_lat_data () const |
accessor to the latitude data buffer | |
float * | get_lon_data () const |
accessor to the longitude data buffer | |
double * | get_time_data () const |
accessor to the timestamps data buffer | |
virtual void | load_pix2data_map () |
build the pixels viewing directions, as a segement from satellite position to viewed pixel center. All positions are stored in Earth Center Rotating carthesian coordinates | |
void | print_pix2data_map () |
print the table that maps the gridded pixels indices to their data representation | |
void | free_pix2data_map () |
free the table that maps the gridded pixels indices to their data representation | |
virtual void | get_viewing_directions (const vector< int > &ipix, vector< Observation > &v_obs) |
viewing directions table accessor | |
virtual bool | is_viewing_directions_data_loaded () |
test if the data requested for computing the viewing directions has been loaded | |
virtual void | load_viewing_directions_data () |
load the data requested for computing the viewing directions | |
virtual void | free_viewing_directions_data () |
free the data requested for computing the viewing directions | |
Protected Types | |
typedef P_Pixel_base< float, vector< int > > | PixelType |
typedef vector< PixelType > ::iterator | I_Pixel |
typedef vector< int > | PixelIndice |
typedef vector< int > | DataIndice |
Protected Attributes | |
float * | lat_data |
float * | lon_data |
double * | time_data |
vector< PixelType > | v_pixel |
std::map< PixelIndice, Carthesian::Segment3D > | viewing_directions |
std::map< PixelIndice, DataIndice > | ipix2idata |
typedef vector<int> SatelliteFileData::DataIndice [protected] |
maps a pixel to its indice in the data. Most of time, it will be exactly the same, but for instance, in the PARASOL data, it will maps a gridded pixel to its record number
typedef vector<int> SatelliteFileData::PixelIndice [protected] |
the lines of sight for all pixels, from satellite position to viewed pixel center. Points are given in Earth Center Rotating carthesian coordinates
virtual const bool SatelliteFileData::contain_data | ( | const float & | lat, | |
const float & | lon, | |||
const double & | time, | |||
const double & | tolerance | |||
) | [pure virtual] |
check if this file has data coincident with (lat,lon,time)
lat | the latitude of the event | |
lon | the longitude of the event | |
time | the time of the event. If -1., time test will be ignored |
Reimplemented from FileData.
Implemented in PARASOLFileData.
virtual const bool SatelliteFileData::contain_location | ( | const float & | lat, | |
const float & | lon, | |||
const double & | tolerance | |||
) | [pure virtual] |
check if this file has eventually data coincident with (lat,lon) Actually, it only tests if (lat,lon) is contained in the data's bounding rectangle.
lat | the latitude of the event | |
lon | the longitude of the event | |
tolerance | acceptable bias between the nearest point in the data and the given (lat,lon) point |
Reimplemented from FileData.
Implemented in PARASOLFileData.
virtual const bool SatelliteFileData::get_index | ( | const float & | lat, | |
const float & | lon, | |||
int & | nearest_pix_idx, | |||
const float | colocation_tolerance | |||
) | [pure virtual] |
find the index of the nearest point to (lat,lon) in the data. If (lat,lon) is not found or out of the colocalisation_frame, returned indexes are [-1,-1]
lat | the latitude | |
lon | the longitude | |
nearest_pix_idx | the index of the nearest measure. -1 if no coincidence found. | |
colocation_tolerance | the acceptable bias (in km or degrees. Supposed to be in, a plane approximation) between [lat,lon] and the nearest data point. |
Implemented in PARASOLFileData.
float* SatelliteFileData::get_lat_data | ( | ) | const [inline] |
float* SatelliteFileData::get_lon_data | ( | ) | const [inline] |
virtual void SatelliteFileData::get_pixel_coord | ( | const vector< int > & | ipix, | |
float & | lat, | |||
float & | lon, | |||
double & | time | |||
) | [pure virtual] |
retrieve the coordinates of a pixel using its index
ipix | [IN] index of the pixel | |
lat | [OUT] latitude of the pixel | |
lon | [OUT] longitude of the pixel | |
time | [OUT] timestamp of the pixel |
Implemented in PARASOLFileData.
double* SatelliteFileData::get_time_data | ( | ) | const [inline] |
virtual const vector< PixelType >& SatelliteFileData::get_v_pixel | ( | ) | const [inline, virtual] |
virtual void SatelliteFileData::get_viewing_directions | ( | const vector< int > & | ipix, | |
vector< Observation > & | v_obs | |||
) | [inline, virtual] |
viewing directions table accessor
ipix | a pixel indice |
ipix | pixel indices | |
v_obs | vector of observation(s). Can contains more than one for directional products |
Reimplemented from FileData.
Reimplemented in PARASOLFileData.
virtual void SatelliteFileData::get_vindex | ( | vector< vector< int > > & | v_index, | |
const float & | lat, | |||
const float & | lon, | |||
const float | colocation_tolerance | |||
) | [pure virtual] |
build the list of indices of pixels that are in colocation tolerance, sorted by increasing distance to (lat,lon) If (lat,lon) is not found or out of the colocalisation_frame, returns an empty vector
v_index | [OUT] the vector of neighbour pixels indices | |
lat | the latitude | |
lon | the longitude | |
colocation_tolerance | the acceptable bias (in km or degrees. Supposed to be in, a plane approximation) between [lat,lon] and the nearest data point. |
Implemented in PARASOLFileData.
virtual void SatelliteFileData::load_pix2data_map | ( | ) | [inline, virtual] |
build the pixels viewing directions, as a segement from satellite position to viewed pixel center. All positions are stored in Earth Center Rotating carthesian coordinates
free the pixels viewing directions, if any set print all the viewing directions build the table that maps the gridded pixels indices to their data representation Most of time, it will be exactly the same, but for instance, in the PARASOL data, it will maps the gridded pixels indices to their matching record number
Reimplemented in PARASOLFileData.
float* SatelliteFileData::lat_data [protected] |
The latitude values
Referenced by free_geolocation_data(), PMFileData::free_geolocation_data(), MODISFileData::free_geolocation_data(), IIRFileData::free_geolocation_data(), DARDARFileData::free_geolocation_data(), CLOUDSATFileData::free_geolocation_data(), CERESFileData::free_geolocation_data(), CALIOPFileData::free_geolocation_data(), MODISFileData::get_5_to_1km_index(), DARDARFileData::get_index(), CLOUDSATFileData::get_index(), CERESFileData::get_index(), CALIOPFileData::get_index(), get_lat_data(), OMIFileData::get_nearest_point_distance(), MODISFileData::get_nearest_point_distance(), IIRFileData::get_nearest_point_distance(), DARDARFileData::get_nearest_point_distance(), CLOUDSATFileData::get_nearest_point_distance(), CERESFileData::get_nearest_point_distance(), CALIOPFileData::get_nearest_point_distance(), OMIFileData::get_nearest_point_index(), IIRFileData::get_nearest_point_index(), DARDARFileData::get_pixel_coord(), CLOUDSATFileData::get_pixel_coord(), CALIOPFileData::get_pixel_coord(), CALIOPFileData::get_viewing_directions(), MODISFileData::get_y_pos_1km_to_250m(), MODISFileData::get_y_pos_5km_to_1km(), MODISFileData::init(), CERESFileData::init(), is_geolocation_data_loaded(), PMFileData::is_geolocation_data_loaded(), MODISFileData::is_geolocation_data_loaded(), IIRFileData::is_geolocation_data_loaded(), CERESFileData::is_geolocation_data_loaded(), CALIOPFileData::is_geolocation_data_loaded(), PMFileData::load_geolocation_data(), OMIFileData::load_geolocation_data(), MODISFileData::load_geolocation_data(), IIRFileData::load_geolocation_data(), DARDARFileData::load_geolocation_data(), CLOUDSATFileData::load_geolocation_data(), CERESFileData::load_geolocation_data(), CALIOPFileData::load_geolocation_data(), MODISFileData::load_v_pixel(), IIRFileData::load_v_pixel(), DARDARFileData::load_v_pixel(), CLOUDSATFileData::load_v_pixel(), CALIOPFileData::load_v_pixel(), and CALIOPFileData::set_lat_lon_min_max().
float* SatelliteFileData::lon_data [protected] |
The longitude values
Referenced by free_geolocation_data(), PMFileData::free_geolocation_data(), MODISFileData::free_geolocation_data(), IIRFileData::free_geolocation_data(), DARDARFileData::free_geolocation_data(), CLOUDSATFileData::free_geolocation_data(), CERESFileData::free_geolocation_data(), CALIOPFileData::free_geolocation_data(), MODISFileData::get_5_to_1km_index(), DARDARFileData::get_index(), CLOUDSATFileData::get_index(), CERESFileData::get_index(), CALIOPFileData::get_index(), get_lon_data(), OMIFileData::get_nearest_point_distance(), MODISFileData::get_nearest_point_distance(), IIRFileData::get_nearest_point_distance(), DARDARFileData::get_nearest_point_distance(), CLOUDSATFileData::get_nearest_point_distance(), CERESFileData::get_nearest_point_distance(), CALIOPFileData::get_nearest_point_distance(), OMIFileData::get_nearest_point_index(), IIRFileData::get_nearest_point_index(), DARDARFileData::get_pixel_coord(), CLOUDSATFileData::get_pixel_coord(), CALIOPFileData::get_pixel_coord(), CALIOPFileData::get_viewing_directions(), MODISFileData::get_y_pos_1km_to_250m(), MODISFileData::get_y_pos_5km_to_1km(), MODISFileData::init(), CERESFileData::init(), is_geolocation_data_loaded(), PMFileData::is_geolocation_data_loaded(), MODISFileData::is_geolocation_data_loaded(), IIRFileData::is_geolocation_data_loaded(), CERESFileData::is_geolocation_data_loaded(), CALIOPFileData::is_geolocation_data_loaded(), PMFileData::load_geolocation_data(), OMIFileData::load_geolocation_data(), MODISFileData::load_geolocation_data(), IIRFileData::load_geolocation_data(), DARDARFileData::load_geolocation_data(), CLOUDSATFileData::load_geolocation_data(), CERESFileData::load_geolocation_data(), CALIOPFileData::load_geolocation_data(), MODISFileData::load_v_pixel(), IIRFileData::load_v_pixel(), DARDARFileData::load_v_pixel(), CLOUDSATFileData::load_v_pixel(), CALIOPFileData::load_v_pixel(), and CALIOPFileData::set_lat_lon_min_max().
double* SatelliteFileData::time_data [protected] |
The time values
Referenced by free_geolocation_data(), PMFileData::free_geolocation_data(), IIRFileData::free_geolocation_data(), DARDARFileData::free_geolocation_data(), CLOUDSATFileData::free_geolocation_data(), CERESFileData::free_geolocation_data(), CALIOPFileData::free_geolocation_data(), DARDARFileData::get_index(), CLOUDSATFileData::get_index(), DARDARFileData::get_pixel_coord(), CLOUDSATFileData::get_pixel_coord(), CALIOPFileData::get_pixel_coord(), get_time_data(), CALIOPFileData::get_viewing_directions(), CERESFileData::init(), is_geolocation_data_loaded(), IIRFileData::is_geolocation_data_loaded(), CERESFileData::is_geolocation_data_loaded(), CALIOPFileData::is_geolocation_data_loaded(), OMIFileData::load_geolocation_data(), IIRFileData::load_geolocation_data(), DARDARFileData::load_geolocation_data(), CLOUDSATFileData::load_geolocation_data(), CERESFileData::load_geolocation_data(), and CALIOPFileData::load_geolocation_data().
vector< PixelType > SatelliteFileData::v_pixel [protected] |
a list of pixels data, sorted by increasing latitude, then increasing longitude
Referenced by free_v_pixel(), OMIFileData::get_index(), DARDARFileData::get_index(), CLOUDSATFileData::get_index(), get_v_pixel(), CALIOPFileData::get_vindex(), DARDARFileData::load_v_pixel(), CLOUDSATFileData::load_v_pixel(), and CALIOPFileData::load_v_pixel().