Coverage – ephemerista.analysis.coverage

The coverage.py module.

This module provides the Coverage class for conducting coverage analyses.

pydantic model ephemerista.analysis.coverage.Coverage

Coverage analysis.

Notes

The coverage is computed by computing all passes of the spacecraft over all points of the exterior of each polygon, i.e. the visibility from the min elevation defined in the polygon’s properties.

Doing that for all points of the exterior of each polygon is computationally intensive, but that allows to do an average of the coverage on the polygon. Besides, when the GroundPoints are created in scenarios.py, shared points between adjacent polygons are merged to avoid duplicate computations.

For instance for a polygon’s exterior composed of 4 points, if two points have spacecraft visibility for a total duration of 340 seconds, and the two other points for 360 seconds, then the average visibility duration of this polygon will be 350 seconds.

Fields:
field end_time: Time | None = None (alias 'endTime')

End time (optional, if None the scenario’s end time is used)

field scenario: Scenario [Required]

The scenario used to analyze the coverage

field start_time: Time | None = None (alias 'startTime')

Start time (optional, if None the scenario’s start time is used)

analyze(ensemble=None, visibility=None)

Run the coverage analysis.

Return type:

CoverageResults

pydantic model ephemerista.analysis.coverage.CoverageResults

Results of the CoverageAnalysis.

Fields:
field coverage_percent: list[float] [Required] (alias 'coveragePercent')

Coverage metric for each polygon, between 0 and 1

field max_time_gaps: list[float] [Required] (alias 'maxTimeGaps')

Maximum time gap in days between successive hits, for each polygon

field polygons: list[Feature[Polygon, dict]] [Required]

List of polygons for which the coverage is computed

field revisit_times: list[list[tuple[Time, Time]]] [Required] (alias 'revisitTimes')

A list of (AOS, LOS) pass times for each polygon

plot_mpl(data_to_plot='coverage_percent', legend=True, **kwargs)

Plot the coverage results using Matplotlib.

Return type:

Axes

plot_plotly(data_to_plot='coverage_percent', mapbox_style='open-street-map', zoom=0, opacity=0.7, **kwargs)

Plot the coverage results using Plotly.

Return type:

Figure

to_geodataframe()

Convert to a GeoDataFrame.

Return type:

GeoDataFrame

ephemerista.analysis.coverage.load_geojson_multipolygon(filename, min_elevation_deg=0.0)

Load polygons from a GeoJSON file.

Parameters:

min_elevation_deg (float) – Minimum elevation in degrees to compute the visibility between a spacecraft and the ground locations

Return type:

list[Feature[Polygon, dict]]

ephemerista.analysis.coverage.polygonize_aoi(aoi_geom_dict, res, min_elevation_deg=0.0)

Polygonize an area of interest using h3.

Parameters:
  • aoi (dict) – A GeoJSON-compatible dict containing a “coordinates” key, usually from a __geo_interface__

  • res (int) – h3 res parameter

  • min_elevation_deg (float) – Minimum elevation in degrees to compute the visibility between a spacecraft and the ground cells

Return type:

list[Feature[Polygon, dict]]