A Python package (with a C++ base) for computing satellite remote-sensing orbit data. (This is a revision of the package in the orbitpy repository.)
The purpose of OrbitPy is to offer a comprehensive set of classes and functions tailored for Earth Observation mission simulations.
Wherever feasible, third-party library classes and functions are leveraged to avoid redundancy. In certain cases, OrbitPy classes act as wrappers around these third-party implementations.
Currently under active development.
Requires: Unix-like operating system, python 3.13, pip
Create a conda environment and install the dependencies:
conda create -n eosim-revised python=3.13
conda activate eosim-revised
conda install sphinx
pip install sphinx-rtd-theme
pip install pylint
pip install black
pip install coverage
pip install skyfield
pip install astropy
Install the eosimutils package: first download the repository and follow the instructions provided in its README file. This package installs the core utilities required by orbitpy.
Once the repository is set up, run the following command in the terminal to complete the installation of orbitpy:
make install
This repository is a revamp of the OrbitPy codebase, primarily aimed at removing the dependency on the propcov library. Instead, we will:
- Use the
CoverageKinematicslibrary for coverage calculations (added as a submodule). - Integrate orbit propagators from third-party libraries such as Skyfield and Orekit.
- Use
PyBind11to create Python bindings for C++ implementations inCoverageKinematics.
The transition away from propcov presents a challenge because several core OrbitPy utility classes rely on wrapped propcov C++ objects (e.g., propcov.OrbitState, propcov.AbsoluteDate). However, this provides an opportunity to:
- Redesign these classes with a cleaner API.
- Incorporate lessons learned from prior development and use of
OrbitPy. - Improve efficiency and maintainability.
For API design, we will reference the following sources:
- OrbitPy library
- Key reference:
docs/api_reference.rstfor high-level descriptions of modules and classes.
- Key reference:
- EOSE-API library
- TAT-C schemas
- InstruPy
- Supports instrument object imports and data metric calculations, while providing default instrument objects.
- SPICE Toolkit
- Cesium CZML
- STK
Each class/function must adhere to the following:
-
Documentation
- Use Sphinx-style inline comments
- Provide descriptive documentation and examples. (similar to SPICE).
-
Testing
- Write unit tests and validation tests.
- Validation data is sourced from other mission simulators (e.g., GMAT or STK) or real-world datasets (e.g., CYGNSS data).
-
Code Style & Standards
- Follow a well-defined Styling README.
- Use Python type hints and follow PEP 8/PEP 257 where applicable.
-
File Handling & Data Structures
- Favor NumPy arrays for representing trajectories.
- Use Python dictionaries for data structures instead of niche objects (AstroPy, SpiceyPy).
- Consider Xarray or Pandas for data indexing.
- AstroPy,
datetime→ Handling time conversions. - Skyfield → SGP4 propagation, TEME frame transformations, Keplerian elements.
- SPICE (SpiceyPy) → Time and coordinate transformations (preferred over AstroPy for speed).
- Orekit → Numerical orbit propagation.
- SciPy → Rotations and interpolation.
- PyBind11 → Python bindings for C++ code.
- Pydantic? → For enforcing data validation in API.
- Leverage existing open-source tools whenever possible instead of reinventing functionality.
- Standardize frame and time representations:
- Frames: ITRF (ECEF), GCRF (ECI).
- Time systems: UTC, UT1.
- Use the latest stable Python version (currently Python 3.13.2).
- Sphinx will be used for documentation.
- Catalog Existing Codebase
- List all classes, functions, and modules in
OrbitPy. - Identify
propcovdependencies that need replacements.
- List all classes, functions, and modules in
Count:
- Modules: 9
- Classes: 9 + 3 + 4 + 2 + 6 + 2 + 2 + 2 + 2 = 33
- Functions: 7 + 0 + 1 + 2 + 4 + 1 + 0 + 1 + 0 = 16
- Examples: ~10
Total: 58 + 10
-
Establish Development Standards
- Create a Styling README for code and documentation.
-
Collaborative Review Process
- Open GitHub discussions for each module/class/function revision.
-
Prototyping & Validation
- Develop prototypes with unit tests and validation cases.
- Get reviews before finalizing implementations.
-
Documentation & Examples
- Generate high-level Sphinx API documentation for each class.
- Update examples to reflect the revised codebase.
Classes
- orbitpy.util.StateType
- orbitpy.util.DateType
- orbitpy.util.OrbitState
- orbitpy.util.SpacecraftBus
- orbitpy.util.Spacecraft
- orbitpy.util.GroundStation
- orbitpy.util.SpaceTrackAPI
- orbitpy.util.OrbitPyDefaults
- orbitpy.util.OutputInfoUtility
Functions
- orbitpy.util.helper_extract_spacecraft_params
- orbitpy.util.extract_auxillary_info_from_state_file
- orbitpy.util.dictionary_list_to_object_list
- orbitpy.util.object_list_to_dictionary_list
- orbitpy.util.initialize_object_list
- orbitpy.util.add_to_list
- orbitpy.util.calculate_inclination_circular_SSO
Classes
- orbitpy.constellation.ConstellationFactory
- orbitpy.constellation.WalkerDeltaConstellation
- orbitpy.constellation.TrainConstellation
Classes
- orbitpy.propagator.PropagatorFactory
- orbitpy.propagator.J2AnalyticalPropagator
- orbitpy.propagator.SGP4Propagator
- orbitpy.propagator.PropagatorOutputInfo
Functions
- orbitpy.propagator.compute_time_step
Classes
- orbitpy.grid.Grid
- orbitpy.grid.GridOutputInfo
Functions
- orbitpy.grid.GridPoint
- orbitpy.grid.compute_grid_res
Classes
- orbitpy.coveragecalculator.CoverageCalculatorFactory
- orbitpy.coveragecalculator.GridCoverage
- orbitpy.coveragecalculator.PointingOptionsCoverage
- orbitpy.coveragecalculator.PointingOptionsWithGridCoverage
- orbitpy.coveragecalculator.SpecularCoverage
- orbitpy.coveragecalculator.CoverageOutputInfo
Functions
- orbitpy.coveragecalculator.helper_extract_coverage_parameters_of_spacecraft
- orbitpy.coveragecalculator.find_in_cov_params_list
- orbitpy.coveragecalculator.filter_mid_interval_access
- orbitpy.coveragecalculator.find_access_intervals
Classes
- orbitpy.contactfinder.ContactFinder
- orbitpy.contactfinder.ContactFinderOutputInfo
Functions
- orbitpy.contactfinder.ContactPairs
Classes
- orbitpy.eclipsefinder.EclipseFinder
- orbitpy.eclipsefinder.EclipseFinderOutputInfo
Classes
- orbitpy.datametricscalculator.DataMetricsCalculator
- orbitpy.datametricscalculator.DataMetricsOutputInfo
Functions
- orbitpy.datametricscalculator.AccessFileInfo
Classes
- orbitpy.mission.Settings
- orbitpy.mission.Mission
### orbitpy.sensorpixelprojection
TBD if time permits.