eopy-orbits 1.0.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- eopy_orbits-1.0.1/.gitignore +95 -0
- eopy_orbits-1.0.1/.gitlab-ci.yml +102 -0
- eopy_orbits-1.0.1/CMakeLists.txt +35 -0
- eopy_orbits-1.0.1/LICENSE +674 -0
- eopy_orbits-1.0.1/PKG-INFO +201 -0
- eopy_orbits-1.0.1/README.md +171 -0
- eopy_orbits-1.0.1/docs/api.md +52 -0
- eopy_orbits-1.0.1/eopy/__init__.py +85 -0
- eopy_orbits-1.0.1/eopy/assets/Orekit-APACHE-2.0.txt +202 -0
- eopy_orbits-1.0.1/eopy/assets/Orekit-NOTICE.txt +16 -0
- eopy_orbits-1.0.1/eopy/assets/dtm_2000.txt +95 -0
- eopy_orbits-1.0.1/eopy/atmosphere.py +352 -0
- eopy_orbits-1.0.1/eopy/constants.py +11 -0
- eopy_orbits-1.0.1/eopy/data.py +288 -0
- eopy_orbits-1.0.1/eopy/dtm2000.py +294 -0
- eopy_orbits-1.0.1/eopy/events.py +63 -0
- eopy_orbits-1.0.1/eopy/frames.py +158 -0
- eopy_orbits-1.0.1/eopy/gravity.py +197 -0
- eopy_orbits-1.0.1/eopy/integrators.py +139 -0
- eopy_orbits-1.0.1/eopy/native.py +183 -0
- eopy_orbits-1.0.1/eopy/profiling.py +59 -0
- eopy_orbits-1.0.1/eopy/propagator.py +318 -0
- eopy_orbits-1.0.1/eopy/py.typed +0 -0
- eopy_orbits-1.0.1/eopy/radiation.py +139 -0
- eopy_orbits-1.0.1/eopy/relativity.py +29 -0
- eopy_orbits-1.0.1/eopy/third_body.py +147 -0
- eopy_orbits-1.0.1/eopy/types.py +9 -0
- eopy_orbits-1.0.1/eopy/version.py +6 -0
- eopy_orbits-1.0.1/examples/atmosphere_models.py +31 -0
- eopy_orbits-1.0.1/examples/download_data_files.py +98 -0
- eopy_orbits-1.0.1/examples/drag_decay.py +71 -0
- eopy_orbits-1.0.1/examples/j2_precession.py +118 -0
- eopy_orbits-1.0.1/examples/native_gravity_model.py +177 -0
- eopy_orbits-1.0.1/examples/propagation_profile.py +59 -0
- eopy_orbits-1.0.1/examples/relativity.py +47 -0
- eopy_orbits-1.0.1/examples/sgp4_comparison.py +103 -0
- eopy_orbits-1.0.1/examples/srp_shadow.py +59 -0
- eopy_orbits-1.0.1/examples/third_body_sun.py +70 -0
- eopy_orbits-1.0.1/examples/two_body_orbit.py +49 -0
- eopy_orbits-1.0.1/pyproject.toml +56 -0
- eopy_orbits-1.0.1/src/eopy_native/eopy_kernels.cpp +187 -0
- eopy_orbits-1.0.1/src/eopy_native/eopy_kernels.h +37 -0
- eopy_orbits-1.0.1/tests/conftest.py +117 -0
- eopy_orbits-1.0.1/tests/precision_orbit/__init__.py +1 -0
- eopy_orbits-1.0.1/tests/precision_orbit/test_precision_orbit.py +463 -0
- eopy_orbits-1.0.1/tests/test_atmosphere.py +216 -0
- eopy_orbits-1.0.1/tests/test_data_native.py +187 -0
- eopy_orbits-1.0.1/tests/test_examples.py +91 -0
- eopy_orbits-1.0.1/tests/test_integrator.py +25 -0
- eopy_orbits-1.0.1/tests/test_numerical_validation.py +233 -0
- eopy_orbits-1.0.1/tests/test_propagator.py +140 -0
- eopy_orbits-1.0.1/tests/test_validation.py +192 -0
- eopy_orbits-1.0.1/tools/check_install.py +27 -0
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
#docs
|
|
2
|
+
*_report
|
|
3
|
+
|
|
4
|
+
# gitlab pages
|
|
5
|
+
public
|
|
6
|
+
|
|
7
|
+
#Sublime
|
|
8
|
+
*.sublime*
|
|
9
|
+
*.code*
|
|
10
|
+
.vscode
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
# Vi/vim editor backup files
|
|
14
|
+
*~
|
|
15
|
+
.*.sw[op]
|
|
16
|
+
|
|
17
|
+
# Byte-compiled / optimized / DLL files
|
|
18
|
+
__pycache__/
|
|
19
|
+
*.py[cod]
|
|
20
|
+
*$py.class
|
|
21
|
+
|
|
22
|
+
# C extensions
|
|
23
|
+
*.so
|
|
24
|
+
*.o
|
|
25
|
+
|
|
26
|
+
# Distribution / packaging
|
|
27
|
+
dist/
|
|
28
|
+
wheelhouse/
|
|
29
|
+
.Python
|
|
30
|
+
develop-eggs/
|
|
31
|
+
eggs/
|
|
32
|
+
.eggs/
|
|
33
|
+
sdist/
|
|
34
|
+
wheels/
|
|
35
|
+
pip-wheel-metadata/
|
|
36
|
+
*.egg-info/
|
|
37
|
+
.installed.cfg
|
|
38
|
+
*.egg
|
|
39
|
+
build/
|
|
40
|
+
|
|
41
|
+
# PyInstaller
|
|
42
|
+
# Usually these files are written by a python script from a template
|
|
43
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
44
|
+
*.manifest
|
|
45
|
+
*.spec
|
|
46
|
+
|
|
47
|
+
# Installer logs
|
|
48
|
+
pip-log.txt
|
|
49
|
+
pip-delete-this-directory.txt
|
|
50
|
+
|
|
51
|
+
# Unit test / coverage reports
|
|
52
|
+
htmlcov/
|
|
53
|
+
.tox/
|
|
54
|
+
.nox/
|
|
55
|
+
.coverage
|
|
56
|
+
.coverage.*
|
|
57
|
+
.cache
|
|
58
|
+
nosetests.xml
|
|
59
|
+
coverage.xml
|
|
60
|
+
*.cover
|
|
61
|
+
.hypothesis/
|
|
62
|
+
.pytest_cache/
|
|
63
|
+
|
|
64
|
+
# Translations
|
|
65
|
+
*.mo
|
|
66
|
+
*.pot
|
|
67
|
+
|
|
68
|
+
# Jupyter Notebook
|
|
69
|
+
.ipynb_checkpoints
|
|
70
|
+
|
|
71
|
+
# IPython
|
|
72
|
+
profile_default/
|
|
73
|
+
ipython_config.py
|
|
74
|
+
|
|
75
|
+
# pyenv
|
|
76
|
+
.python-version
|
|
77
|
+
|
|
78
|
+
# Environments
|
|
79
|
+
.env
|
|
80
|
+
.venv
|
|
81
|
+
env/
|
|
82
|
+
venv/
|
|
83
|
+
ENV/
|
|
84
|
+
env.bak/
|
|
85
|
+
venv.bak/
|
|
86
|
+
|
|
87
|
+
# mypy
|
|
88
|
+
.mypy_cache/
|
|
89
|
+
.dmypy.json
|
|
90
|
+
dmypy.json
|
|
91
|
+
|
|
92
|
+
# misc output and logs
|
|
93
|
+
logfile
|
|
94
|
+
cache_error*
|
|
95
|
+
*.log
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
image: python:3.14
|
|
2
|
+
|
|
3
|
+
stages:
|
|
4
|
+
- test
|
|
5
|
+
- type_checking
|
|
6
|
+
- release
|
|
7
|
+
|
|
8
|
+
.devsetup:
|
|
9
|
+
before_script:
|
|
10
|
+
- apt-get update && apt-get install -y g++ cmake
|
|
11
|
+
- python -m pip install '.[develop]'
|
|
12
|
+
- cmake -S . -B build/native -DCMAKE_BUILD_TYPE=Release
|
|
13
|
+
- cmake --build build/native --config Release
|
|
14
|
+
|
|
15
|
+
pytest:
|
|
16
|
+
extends: .devsetup
|
|
17
|
+
stage: test
|
|
18
|
+
parallel:
|
|
19
|
+
matrix:
|
|
20
|
+
- PYTHON: ['3.11', '3.12', '3.13', '3.14']
|
|
21
|
+
image: python:$PYTHON
|
|
22
|
+
script:
|
|
23
|
+
- python -c 'from eopy import native; assert native.available()'
|
|
24
|
+
- python -m pytest --ignore=tests/precision_orbit
|
|
25
|
+
- python -m pytest --ignore=tests/precision_orbit --python-backend
|
|
26
|
+
only:
|
|
27
|
+
- merge_requests
|
|
28
|
+
- main
|
|
29
|
+
- develop
|
|
30
|
+
- tags
|
|
31
|
+
|
|
32
|
+
quality:
|
|
33
|
+
extends: .devsetup
|
|
34
|
+
stage: type_checking
|
|
35
|
+
script:
|
|
36
|
+
- ruff check eopy tests examples tools
|
|
37
|
+
- ruff format --check eopy tests examples tools
|
|
38
|
+
- mypy eopy
|
|
39
|
+
only:
|
|
40
|
+
- merge_requests
|
|
41
|
+
- main
|
|
42
|
+
- develop
|
|
43
|
+
- tags
|
|
44
|
+
|
|
45
|
+
sdist:
|
|
46
|
+
extends: .devsetup
|
|
47
|
+
stage: release
|
|
48
|
+
script:
|
|
49
|
+
- python -m build --sdist
|
|
50
|
+
- python -m pip wheel --no-deps dist/*.tar.gz -w rebuilt
|
|
51
|
+
- python -m twine check dist/*
|
|
52
|
+
artifacts:
|
|
53
|
+
paths: [dist/]
|
|
54
|
+
only:
|
|
55
|
+
- tags
|
|
56
|
+
|
|
57
|
+
wheels:
|
|
58
|
+
stage: release
|
|
59
|
+
image: quay.io/pypa/manylinux_2_28_x86_64
|
|
60
|
+
parallel:
|
|
61
|
+
# Because we have compiled components, we run in matrix
|
|
62
|
+
matrix:
|
|
63
|
+
- CPYTHON: ['311', '312', '313', '314']
|
|
64
|
+
script:
|
|
65
|
+
- export PATH="/opt/python/cp${CPYTHON}-cp${CPYTHON}/bin:$PATH"
|
|
66
|
+
- python -m pip install build twine
|
|
67
|
+
- python -m build --wheel
|
|
68
|
+
- auditwheel repair dist/*.whl -w wheelhouse
|
|
69
|
+
- python -m twine check wheelhouse/*
|
|
70
|
+
- python -m pip install wheelhouse/*.whl
|
|
71
|
+
- cp tools/check_install.py /tmp/eopy_check_install.py
|
|
72
|
+
- cd /tmp && python eopy_check_install.py
|
|
73
|
+
artifacts:
|
|
74
|
+
paths: [wheelhouse/]
|
|
75
|
+
only:
|
|
76
|
+
- tags
|
|
77
|
+
|
|
78
|
+
precision:
|
|
79
|
+
extends: .devsetup
|
|
80
|
+
stage: test
|
|
81
|
+
variables:
|
|
82
|
+
EOPY_DATA_PATH: /tmp/eopy-data
|
|
83
|
+
script:
|
|
84
|
+
# remember to set EOPY_DATA in GitLab CI variables (a url poiting to a .tar.gz archive).
|
|
85
|
+
- apt-get install -y curl
|
|
86
|
+
- curl --fail --location --silent --show-error "${EOPY_DATA:?Set EOPY_DATA in GitLab CI variables}" --output /tmp/eopy-reference.tar.gz
|
|
87
|
+
- mkdir -p "$EOPY_DATA_PATH"
|
|
88
|
+
- tar -xzf /tmp/eopy-reference.tar.gz --strip-components=1 -C "$EOPY_DATA_PATH"
|
|
89
|
+
- sha256sum "$EOPY_DATA_PATH"/*
|
|
90
|
+
- python -m pytest tests/precision_orbit --require-precision -s --precision-orbit-file "$EOPY_DATA_PATH/sentinel_2b_20240704.eof" --gravity-model-file "$EOPY_DATA_PATH/EIGEN-6S4_v2.gfc" --space-weather-file "$EOPY_DATA_PATH/SW-All.csv"
|
|
91
|
+
only:
|
|
92
|
+
- tags
|
|
93
|
+
|
|
94
|
+
pypi:
|
|
95
|
+
stage: release
|
|
96
|
+
needs: [pytest, quality, sdist, wheels, precision]
|
|
97
|
+
script:
|
|
98
|
+
- python -m pip install twine
|
|
99
|
+
- python -m twine check dist/* wheelhouse/*
|
|
100
|
+
- TWINE_USERNAME=__token__ TWINE_PASSWORD="${PYPI_TOKEN:?Set PYPI_TOKEN in GitLab CI variables}" python -m twine upload --non-interactive --verbose dist/* wheelhouse/*
|
|
101
|
+
only:
|
|
102
|
+
- tags
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
cmake_minimum_required(VERSION 3.18)
|
|
2
|
+
project(eopy_native LANGUAGES CXX)
|
|
3
|
+
|
|
4
|
+
add_library(eopykernels SHARED
|
|
5
|
+
src/eopy_native/eopy_kernels.cpp
|
|
6
|
+
)
|
|
7
|
+
|
|
8
|
+
# Read the same literal used by Python and scikit-build-core's metadata provider.
|
|
9
|
+
# Reconfigure when it changes, including during an incremental native build.
|
|
10
|
+
set(EOPY_VERSION_FILE "${PROJECT_SOURCE_DIR}/eopy/version.py")
|
|
11
|
+
set_property(DIRECTORY APPEND PROPERTY CMAKE_CONFIGURE_DEPENDS "${EOPY_VERSION_FILE}")
|
|
12
|
+
file(STRINGS "${EOPY_VERSION_FILE}" EOPY_VERSION_LINE REGEX "^__version__ = ")
|
|
13
|
+
string(REGEX REPLACE "^__version__ = \"([^\"]+)\"$" "\\1" EOPY_VERSION "${EOPY_VERSION_LINE}")
|
|
14
|
+
target_compile_definitions(eopykernels PRIVATE EOPY_VERSION="${EOPY_VERSION}")
|
|
15
|
+
|
|
16
|
+
target_compile_features(eopykernels PRIVATE cxx_std_17)
|
|
17
|
+
target_include_directories(eopykernels PUBLIC src/eopy_native)
|
|
18
|
+
set_target_properties(eopykernels PROPERTIES
|
|
19
|
+
POSITION_INDEPENDENT_CODE ON
|
|
20
|
+
CXX_VISIBILITY_PRESET hidden
|
|
21
|
+
VISIBILITY_INLINES_HIDDEN ON
|
|
22
|
+
ARCHIVE_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}"
|
|
23
|
+
)
|
|
24
|
+
|
|
25
|
+
if(NOT SKBUILD)
|
|
26
|
+
set_target_properties(eopykernels PROPERTIES
|
|
27
|
+
LIBRARY_OUTPUT_DIRECTORY "${PROJECT_SOURCE_DIR}/eopy"
|
|
28
|
+
RUNTIME_OUTPUT_DIRECTORY "${PROJECT_SOURCE_DIR}/eopy")
|
|
29
|
+
endif()
|
|
30
|
+
|
|
31
|
+
install(TARGETS eopykernels
|
|
32
|
+
LIBRARY DESTINATION eopy
|
|
33
|
+
RUNTIME DESTINATION eopy
|
|
34
|
+
ARCHIVE DESTINATION eopy
|
|
35
|
+
)
|