Coverage module
Contents
Coverage module¶
The coverage
module holds the classes that support the modelling, computation and writting of observations
geometry metadata: GeometryParameters
and footprint (GeoJSON Feature).
T_STEPS_MAX
¶
- geogen.coverage.T_STEPS_MAX = 100¶
Maximum number of computation steps per observation.
CoverageList
class¶
- class geogen.coverage.CoverageList[source]¶
Bases:
object
Class that represents a collection of observation coverages.
Constructs CoverageList object.
- get_coverage(observation)[source]¶
Returns the coverage in each a given observation is contained.
- Parameters
observation (Observation) – Input Observation object.
- Return type
Coverage
class¶
- class geogen.coverage.Coverage(observation)[source]¶
Bases:
object
Class that represents a collection of observation, grouped by target, instrument host and data product types.
- surface_model¶
Target surface model to be used for computation of observations geometry metadata, which can be ‘ELLIPSOID’ (default) or ‘DSK/UNPRIORITIZED’.
- Type
- antimeridian_split¶
Whether or not (default) coverage observations footprints are split when crossing the target body’s antimeridian.
- Type
- observations¶
List of Observation objects within this coverage.
- Type
List[Observation]
Constructs Coverage object.
- Parameters
observation (Observation) – Input Observation object.
- get_name()[source]¶
Get coverage name (coverage name without the surface-model and antimeridian-split related suffixes).
- Return type
- add_observation(observation)[source]¶
Add an observation to the coverage.
- Parameters
observation (Observation) – Input Observation object to be added.
- compute_geometry(surface_model='ELLIPSOID')[source]¶
Compute coverage observations geometry metadata.
- Parameters
surface_model (str, optional) – Surface model to be used for computation of observations geometry metadata, which can be ‘ELLIPSOID’ (default) or ‘DSK/UNPRIORITIZED’.
- derive_footprints(split=False)[source]¶
Derive coverage observations footprints.
- Parameters
split (bool) – Whether or not (default) coverage observations footprints are split when crossing the target body’s antimeridian.
- write_B3F(output_dir)[source]¶
Write output coverage B3F file.
- Parameters
output_dir (str) – Output directory path of B3F file.
- write_GeoJSON(output_dir, dsk_files=[])[source]¶
Write output Coverage GeoJSON File.
Observation
class¶
- class geogen.coverage.Observation(product, forced_target='', force_detector=False)[source]¶
Bases:
object
Class that represents an observation associated to a PDS observational data product.
- geometry_parameters¶
Observation geometry parameters.
- Type
- footprint¶
Observation footprint.
- Type
Constructs Observation object.
- Parameters
- compute_geometries(surface_model='ELLIPSOID')[source]¶
Compute Observation Geometry objects.
- Parameters
surface_model – Target surface model to be used for computation, which can be ‘ELLIPSOID’ (default) or ‘DSK/UNPRIORITIZED’.
- derive_geometry_parameters()[source]¶
Derive geometry parameters based on observation ephemeris times and Geometriy objects.
Handled by the
geogen.coverage.GeometryParameters.derive()
method.
- derive_footprint(split=False)[source]¶
Derive observation footprint.
Derive GeoJSON Feature geometry and properties from computed geometry parameters for each frustum boresight and pointing vectors. Boundary box coordinates and whether or not the footprint geometry is crossing the target body’s antimeridian, North Pole and South Pole, is performed using
geogen.tamn.get_bbox()
function.Splitting of footprint geometry is performed using the
geogen.tamn.getSplitFeature()
function.- Parameters
split – Whether or not (default) coverage observations footprints are split when crossing the target body’s antimeridian.
Detector
class¶
- class geogen.coverage.Detector(detector_name, detector_mode=1, detector_fov_ref_ratio=1.0, detector_fov_cross_ratio=1.0, force_detector=False)[source]¶
Bases:
object
Class that represents the detector associated to an Observation.
- fov_ref_ratio¶
FRAME detector sub-frame FOV reference-axis ratio for a given observation.
- Type
Constructs Detector object.
- Parameters
detector_name (str) – SPICE detector name.
detector_mode (int) – Detector mode used for a given observation (default is 1).
detector_fov_ref_ratio (float) – Detector sub-frame FOV reference-axis ratio for a given observation.
detector_fov_cross_ratio (float) – Detector sub-frame FOV reference-axis ratio for a given observation.
- get_type()[source]¶
Returns the detector type: ‘IN-SITU’ (default), ‘POINT’, ‘LINE’, or ‘FRAME’.
- Return type
- get_geometry()[source]¶
Returns the detector pointing vectors and across-track instantaneous field-of-view (iFOV).
IN-SITU and POINT detectors have no pointing vectors.
LINE detectors have two pointing vectors defining an angle-of-view (AOV).
FRAME detectors have multiple interpolated pointing vectors defintion a fied-of-view (FOV).
- get_pointing_vectors(interpolated=True)[source]¶
Returns detector pointing vectors, whether interpolated or not.
Note that LINE detector AOV pointing vectors are not interpolated.
Target
class¶
Geometry
class¶
- class geogen.coverage.Geometry[source]¶
Bases:
object
Class that represents the geometrical state of an observation at a given time/computation step.
A collection of Geometry objects is used to derive the
GeometryParameters
andfootprint
associated to a givenObservation
.See Geometry class source code for the list of attributes.
GeometryParameters
class¶
- class geogen.coverage.GeometryParameters[source]¶
Bases:
object
Class that holds and derive the geometry parameters of an observation.
Each of the following attribute is a property of an observation footprint within output Coverage GeoJSON files, meant for ingestion into the PSA DB and for visualisation on the PSA map-based UI.
Geometry parameters are derived from individual measurement geometries computed by the
geogen.coverage.Observation.compute_geometries()
method.Longitudes and latitudes are expressed in planetocentric coordinate system, in degrees.
All angles are expressed in degrees.
All distance are expressed in kilometers.
- reference_time¶
Reference UTC time at which most geometry parameters are computed (min_*/max_* parameters are computed taking into account for all observation geometry computation times. The reference time is defined as the time between the start and stop time).
- Type
- solar_longitude¶
Planetocentric longitude (Ls) of the sun for the target body at the reference time. The planetocentric longitude is the angle between the body-sun vector at the time of interest and the body-sun vector at the vernal equinox.
- Type
- sub_solar_latitude¶
Latitude of the sub-solar point on the target body at the reference time. The sub-solar point is the point on a body’s reference surface where a line from the body center to the sun center intersects that surface.
- Type
- sub_solar_longitude¶
Longitude of the sub-solar point on the target body at the reference time. The sub-solar point is the point on a body’s reference surface where a line from the body center to the sun center intersects that surface.
- Type
- solar_distance¶
Distance from the center of the sun to the center of the target body at the reference time.
- Type
- spacecraft_solar_distance¶
Distance from the spacecraft to the center of the sun at the reference time.
- Type
- spacecraft_altitude¶
Distance from the spacecraft to the sub-spacecraft point on the target body at the reference time.
- Type
- target_center_distance¶
Distance from the spacecraft to the center of the target body at the treference time.
- Type
- sub_spacecraft_latitude¶
Latitude of the sub-spacecraft point on the target body at the reference time.
- Type
- sub_spacecraft_longitude¶
Longitude of the sub-spacecraft point on the target body at the reference time.
- Type
- sub_spacecraft_solar_zenith_angle¶
Solar zenith angle at the sub-spacecraft point on the target body surface at the reference time. The solar zenith angle is the angle subtended between the direction towards the Sun and the local normal at the surface.
- Type
- target_right_ascension¶
Right ascension of the position vector of the target body center as seen from the spacecraft in the Earth mean equator and equinox frame (J2000).
- Type
- target_declination¶
Declination of the position vector of the target body center as seen from the spacecraft in the Earth mean equator and equinox frame (J2000).
- Type
- sun_right_ascension¶
Right ascension of the position vector of the Sun as seen from the spacecraft in the Earth mean equator and equinox frame (J2000).
- Type
- sun_declination¶
Declination of the position vector of the Sun as seen from the spacecraft in the Earth mean equator and equinox frame (J2000).
- Type
- x_sc_sun_position¶
X component of the position vector from spacecraft to Sun, expressed in J2000 coordinates, and corrected for light time and stellar aberration, evaluated at the reference time.
- Type
- y_sc_sun_position¶
Y component of the position vector from spacecraft to Sun, expressed in J2000 coordinates, and corrected for light time and stellar aberration, evaluated at the reference time.
- Type
- z_sc_sun_position¶
Z component of the position vector from spacecraft to Sun, expressed in J2000 coordinates, and corrected for light time and stellar aberration, evaluated at the reference time.
- Type
- x_sc_sun_velocity¶
X component of the velocity vector of Sun relative to the spacecraft, expressed in J2000 coordinates, and corrected for light time and stellar aberration, evaluated at the reference time.
- Type
- y_sc_sun_velocity¶
Y component of the velocity vector of Sun relative to the spacecraft, expressed in J2000 coordinates, and corrected for light time and stellar aberration, evaluated at the reference time.
- Type
- z_sc_sun_velocity¶
Z component of the velocity vector of Sun relative to the spacecraft, expressed in J2000 coordinates, and corrected for light time and stellar aberration, evaluated at the reference time.
- Type
- x_sc_target_position¶
X component of the position vector from the spacecraft to target body center, expressed in J2000 coordinates, and corrected for light time and stellar aberration, evaluated at the reference time.
- Type
- y_sc_target_position¶
Y component of the position vector from the spacecraft to target body center, expressed in J2000 coordinates, and corrected for light time and stellar aberration, evaluated at the reference time.
- Type
- z_sc_target_position¶
Z component of the position vector from the spacecraft to target body center, expressed in J2000 coordinates, and corrected for light time and stellar aberration, evaluated at the reference time.
- Type
- x_sc_target_velocity¶
X component of the velocity vector of the target body center relative to the spacecraft, expressed in J2000 coordinates, and corrected for light time and stellar aberration, evaluated at the reference time.
- Type
- y_sc_target_velocity¶
Y component of the velocity vector of the target body center relative to the spacecraft, expressed in J2000 coordinates, and corrected for light time and stellar aberration, evaluated at the reference time.
- Type
- z_sc_target_velocity¶
Z component of the velocity vector of the target body center relative to the spacecraft, expressed in J2000 coordinates, and corrected for light time and stellar aberration, evaluated at the reference time.
- Type
- boresight_right_ascension¶
Right ascension of the detector boresight vector, in the Earth mean equator and equinox frame (J2000), at the reference time.
- Type
- boresight_declination¶
Declination of the detector boresight vector, in the Earth mean equator and equinox frame (J2000), at the reference time.
- Type
- boresight_target_angle¶
The separation angle between the detector line-of-sight (boresight) and the target body center as seen from the spacecraft, at the reference time.
- Type
- boresight_solar_elongation¶
Separation angle between the detector line-of-sight and the position vector of the Sun as seen from the spacecraft, at the reference time.
- Type
- antimeridian_crossing¶
Whether or not observation footprint is crossing the target body antimeridian.
- Type
- npole_crossing¶
Whether or not observation footprint is crossing the target body North Pole.
- Type
- spole_crossing¶
Whether or not observation footprint is crossing the target body South Pole.
- Type
- local_true_solar_time¶
Local solar time for the surface point, evaluated at the reference time. The local solar time is the angle between the planetocentric longitude of the Sun, as viewed from the center of the target body, and the planetocentric longitude of the surface point, expressed on a “24 hour” clock.
- Type
- min_incidence_angle¶
Minimum incidence angle. The incidence angle is the angle between the local vertical at a given surface point and the vector from the surface point to the sun.
- Type
- max_incidence_angle¶
Maximum incidence angle. The incidence angle is the angle between the local vertical at a given surface point and the vector from that the surface point to the sun.
- Type
- min_emergence_angle¶
Minimum emission angle. The emission angle is the angle between the surface normal at a given surface point and the vector from the surface point to the spacecraft.
- Type
- max_emergence_angle¶
Maximum emission angle. The emission angle is the angle between the surface normal at a given surface point and the vector from the surface point to the spacecraft.
- Type
- min_phase_angle¶
Minimum phase angle. The phase angle is the angle between the vectors from the surface point to the spacecraft and from the surface point to the Sun.
- Type
- max_phase_angle¶
Maximum phase angle. The phase angle is the angle between the vectors from the surface point to the spacecraft and from the surface point to the Sun.
- Type
- min_slant_distance¶
Minimum slant distance. The slant distance is the distance from the spacecraft to the nearest point on the detector line-of-sight to the target body surface.
- Type
- max_slant_distance¶
Maximum slant distance. The slant distance is the distance from the spacecraft to the nearest point on the detector line-of-sight to the target body surface.
- Type
- min_tangent_altitude¶
Minimum tangent altitude. The tangent altitude is the distance from the target body surface nearest point to the detector line-of-sight.
- Type
- max_tangent_altitude¶
Maximum tangent altitude. The tangent altitude is the distance from the target body surface nearest point to the detector line-of-sight.
- Type
- min_spatial_resolution¶
Minimum across-track instantaneous field-of-view (iFOV) target point spatial resolution.
- Type
- max_spatial_resolution¶
Maximum across-track instantaneous field-of-view (iFOV) target point spatial resolution.
- Type
Constructs GeometryParameters object.