keplemon 3.1.1__cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
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.
- keplemon/.DS_Store +0 -0
- keplemon/._.DS_Store +0 -0
- keplemon/._arm +0 -0
- keplemon/._libastrofunc.so +0 -0
- keplemon/._libdllmain.so +0 -0
- keplemon/._libelops.so +0 -0
- keplemon/._libenvconst.so +0 -0
- keplemon/._libextephem.so +0 -0
- keplemon/._libobs.so +0 -0
- keplemon/._libsatstate.so +0 -0
- keplemon/._libsensor.so +0 -0
- keplemon/._libsgp4prop.so +0 -0
- keplemon/._libspvec.so +0 -0
- keplemon/._libtimefunc.so +0 -0
- keplemon/._libtle.so +0 -0
- keplemon/._libvcm.so +0 -0
- keplemon/EGM-2008.GEO +2563 -0
- keplemon/EGM-96.GEO +2563 -0
- keplemon/JPLcon_1950_2050.405 +392370 -0
- keplemon/SGP4_Open_License.txt +186 -0
- keplemon/WGS84-70.GEO +2563 -0
- keplemon/__init__.py +33 -0
- keplemon/__init__.pyi +54 -0
- keplemon/__main__.py +20 -0
- keplemon/_keplemon.abi3.so +0 -0
- keplemon/bodies.py +8 -0
- keplemon/bodies.pyi +367 -0
- keplemon/catalogs.py +5 -0
- keplemon/catalogs.pyi +19 -0
- keplemon/elements.py +39 -0
- keplemon/elements.pyi +521 -0
- keplemon/enums.py +21 -0
- keplemon/enums.pyi +120 -0
- keplemon/estimation.py +9 -0
- keplemon/estimation.pyi +200 -0
- keplemon/events.py +17 -0
- keplemon/events.pyi +103 -0
- keplemon/exceptions.py +5 -0
- keplemon/libastrofunc.so +0 -0
- keplemon/libdllmain.so +0 -0
- keplemon/libelops.so +0 -0
- keplemon/libenvconst.so +0 -0
- keplemon/libextephem.so +0 -0
- keplemon/libobs.so +0 -0
- keplemon/libsatstate.so +0 -0
- keplemon/libsensor.so +0 -0
- keplemon/libsgp4prop.so +0 -0
- keplemon/libspvec.so +0 -0
- keplemon/libtimefunc.so +0 -0
- keplemon/libtle.so +0 -0
- keplemon/libvcm.so +0 -0
- keplemon/propagation.py +15 -0
- keplemon/propagation.pyi +50 -0
- keplemon/py.typed +0 -0
- keplemon/time.py +96 -0
- keplemon/time.pyi +293 -0
- keplemon/time_constants.dat +19472 -0
- keplemon-3.1.1.dist-info/METADATA +21 -0
- keplemon-3.1.1.dist-info/RECORD +76 -0
- keplemon-3.1.1.dist-info/WHEEL +5 -0
- keplemon-3.1.1.dist-info/entry_points.txt +2 -0
- keplemon.libs/libastrofunc-d5d29f1a.so +0 -0
- keplemon.libs/libdllmain-83b073db.so +0 -0
- keplemon.libs/libelops-d6961cbd.so +0 -0
- keplemon.libs/libenvconst-5ff8e89b.so +0 -0
- keplemon.libs/libextephem-9ddad493.so +0 -0
- keplemon.libs/libgfortran-daac5196.so.5 +0 -0
- keplemon.libs/libgomp-d22c30c5.so.1 +0 -0
- keplemon.libs/libobs-acba28cb.so +0 -0
- keplemon.libs/libsatstate-a0706992.so +0 -0
- keplemon.libs/libsensor-15ffa85c.so +0 -0
- keplemon.libs/libsgp4prop-8300f9d3.so +0 -0
- keplemon.libs/libspvec-b3cef8a2.so +0 -0
- keplemon.libs/libtimefunc-d4915652.so +0 -0
- keplemon.libs/libtle-72004375.so +0 -0
- keplemon.libs/libvcm-460d66c8.so +0 -0
keplemon/time.pyi
ADDED
|
@@ -0,0 +1,293 @@
|
|
|
1
|
+
# flake8: noqa
|
|
2
|
+
from __future__ import annotations
|
|
3
|
+
from pathlib import Path
|
|
4
|
+
from keplemon.enums import TimeSystem
|
|
5
|
+
from typing import overload, Any, Union
|
|
6
|
+
from datetime import datetime
|
|
7
|
+
|
|
8
|
+
def request_time_constants_update(output_path: Union[str, Path]) -> None:
|
|
9
|
+
"""
|
|
10
|
+
Request time constants and EOP data from USNO and save to the specified path.
|
|
11
|
+
|
|
12
|
+
Args:
|
|
13
|
+
output_path: Path where the SAAL-formatted time constants will be written
|
|
14
|
+
"""
|
|
15
|
+
...
|
|
16
|
+
|
|
17
|
+
class TimeSpan:
|
|
18
|
+
@classmethod
|
|
19
|
+
def from_days(cls, days: float) -> TimeSpan:
|
|
20
|
+
"""
|
|
21
|
+
Args:
|
|
22
|
+
days: Total duration in days
|
|
23
|
+
"""
|
|
24
|
+
...
|
|
25
|
+
|
|
26
|
+
@classmethod
|
|
27
|
+
def from_seconds(cls, seconds: float) -> TimeSpan:
|
|
28
|
+
"""
|
|
29
|
+
Args:
|
|
30
|
+
seconds: Total duration in seconds
|
|
31
|
+
"""
|
|
32
|
+
...
|
|
33
|
+
|
|
34
|
+
@classmethod
|
|
35
|
+
def from_minutes(cls, minutes: float) -> TimeSpan:
|
|
36
|
+
"""
|
|
37
|
+
Args:
|
|
38
|
+
minutes: Total duration in minutes
|
|
39
|
+
"""
|
|
40
|
+
...
|
|
41
|
+
|
|
42
|
+
@classmethod
|
|
43
|
+
def from_hours(cls, hours: float) -> TimeSpan:
|
|
44
|
+
"""
|
|
45
|
+
Args:
|
|
46
|
+
hours: Total duration in hours
|
|
47
|
+
"""
|
|
48
|
+
...
|
|
49
|
+
|
|
50
|
+
def in_days(self) -> float:
|
|
51
|
+
"""
|
|
52
|
+
Returns:
|
|
53
|
+
Total duration in days
|
|
54
|
+
"""
|
|
55
|
+
...
|
|
56
|
+
|
|
57
|
+
def in_seconds(self) -> float:
|
|
58
|
+
"""
|
|
59
|
+
Returns:
|
|
60
|
+
Total duration in seconds
|
|
61
|
+
"""
|
|
62
|
+
...
|
|
63
|
+
|
|
64
|
+
def in_minutes(self) -> float:
|
|
65
|
+
"""
|
|
66
|
+
Returns:
|
|
67
|
+
Total duration in minutes
|
|
68
|
+
"""
|
|
69
|
+
...
|
|
70
|
+
|
|
71
|
+
def in_hours(self) -> float:
|
|
72
|
+
"""
|
|
73
|
+
Returns:
|
|
74
|
+
Total duration in hours
|
|
75
|
+
"""
|
|
76
|
+
...
|
|
77
|
+
|
|
78
|
+
class TimeComponents:
|
|
79
|
+
year: int
|
|
80
|
+
""""""
|
|
81
|
+
|
|
82
|
+
month: int
|
|
83
|
+
""""""
|
|
84
|
+
|
|
85
|
+
day: int
|
|
86
|
+
""""""
|
|
87
|
+
|
|
88
|
+
hour: int
|
|
89
|
+
""""""
|
|
90
|
+
|
|
91
|
+
minute: int
|
|
92
|
+
""""""
|
|
93
|
+
|
|
94
|
+
second: float
|
|
95
|
+
""""""
|
|
96
|
+
|
|
97
|
+
def __init__(
|
|
98
|
+
self,
|
|
99
|
+
year: int,
|
|
100
|
+
month: int,
|
|
101
|
+
day: int,
|
|
102
|
+
hour: int,
|
|
103
|
+
minute: int,
|
|
104
|
+
second: float,
|
|
105
|
+
) -> None:
|
|
106
|
+
"""
|
|
107
|
+
Initialize TimeComponents with the given year, month, day, hour, minute, and second.
|
|
108
|
+
|
|
109
|
+
!!! warning
|
|
110
|
+
It is the user's responsibility to input valid month/day combinations and time values. This class does not
|
|
111
|
+
perform validation.
|
|
112
|
+
|
|
113
|
+
Args:
|
|
114
|
+
year: Year (e.g., 2023)
|
|
115
|
+
month: Month (1-12)
|
|
116
|
+
day: Day (1-31)
|
|
117
|
+
hour: Hour (0-23)
|
|
118
|
+
minute: Minute (0-59)
|
|
119
|
+
second: Second (0.0-59.999...)
|
|
120
|
+
"""
|
|
121
|
+
|
|
122
|
+
def to_iso(self) -> str:
|
|
123
|
+
"""
|
|
124
|
+
Returns:
|
|
125
|
+
Epoch in ISO 8601 format (YYYY-MM-DDThh:mm:ss.sss)
|
|
126
|
+
"""
|
|
127
|
+
...
|
|
128
|
+
|
|
129
|
+
@classmethod
|
|
130
|
+
def from_iso(cls, iso_str: str) -> TimeComponents:
|
|
131
|
+
"""
|
|
132
|
+
Args:
|
|
133
|
+
iso_str: ISO 8601 formatted string (YYYY-MM-DDThh:mm:ss.sss)
|
|
134
|
+
"""
|
|
135
|
+
...
|
|
136
|
+
|
|
137
|
+
class Epoch:
|
|
138
|
+
days_since_1950: float
|
|
139
|
+
"""
|
|
140
|
+
Core floating epoch representation used by the SAAL binaries.
|
|
141
|
+
"""
|
|
142
|
+
|
|
143
|
+
time_system: TimeSystem
|
|
144
|
+
""""""
|
|
145
|
+
|
|
146
|
+
day_of_year: float
|
|
147
|
+
"""Decimal day of the year (1-365.999...)"""
|
|
148
|
+
|
|
149
|
+
def to_datetime(self) -> datetime:
|
|
150
|
+
"""
|
|
151
|
+
Returns:
|
|
152
|
+
Aware datetime object in UTC time system
|
|
153
|
+
"""
|
|
154
|
+
...
|
|
155
|
+
|
|
156
|
+
@classmethod
|
|
157
|
+
def from_datetime(cls, dt: datetime) -> Epoch:
|
|
158
|
+
"""
|
|
159
|
+
Args:
|
|
160
|
+
dt: Aware or naive datetime object (assumed to be UTC if naive)
|
|
161
|
+
"""
|
|
162
|
+
...
|
|
163
|
+
|
|
164
|
+
@classmethod
|
|
165
|
+
def now(cls) -> Epoch:
|
|
166
|
+
"""
|
|
167
|
+
Returns:
|
|
168
|
+
Current epoch in UTC time system
|
|
169
|
+
"""
|
|
170
|
+
...
|
|
171
|
+
|
|
172
|
+
@classmethod
|
|
173
|
+
def from_days_since_1950(cls, days: float, time_system: TimeSystem) -> Epoch:
|
|
174
|
+
"""
|
|
175
|
+
Args:
|
|
176
|
+
days: Days since 1 Jan 1956
|
|
177
|
+
time_system: System used to calculate the number of days since 1 Jan 1956
|
|
178
|
+
"""
|
|
179
|
+
...
|
|
180
|
+
|
|
181
|
+
@classmethod
|
|
182
|
+
def from_iso(cls, iso_str: str, time_system: TimeSystem) -> Epoch:
|
|
183
|
+
"""
|
|
184
|
+
Args:
|
|
185
|
+
iso_str: ISO 8601 formatted string (YYYY-MM-DDThh:mm:ss.sss)
|
|
186
|
+
time_system: System used to calculate the epoch
|
|
187
|
+
"""
|
|
188
|
+
...
|
|
189
|
+
|
|
190
|
+
@classmethod
|
|
191
|
+
def from_time_components(cls, components: TimeComponents, time_system: TimeSystem) -> Epoch:
|
|
192
|
+
"""
|
|
193
|
+
Args:
|
|
194
|
+
components: Epoch represented as individual components
|
|
195
|
+
time_system: System used to calculate the epoch
|
|
196
|
+
"""
|
|
197
|
+
...
|
|
198
|
+
|
|
199
|
+
@classmethod
|
|
200
|
+
def from_dtg(cls, dtg: str, time_system: TimeSystem) -> Epoch:
|
|
201
|
+
"""
|
|
202
|
+
Create an epoch from a standard SAAL DTG format.
|
|
203
|
+
|
|
204
|
+
!!! note
|
|
205
|
+
DTG formats include:
|
|
206
|
+
|
|
207
|
+
- DTG 20: YYYY/DDD HHMM SS.SSS
|
|
208
|
+
- DTG 19: YYYYMonDDHHMMSS.SSS
|
|
209
|
+
- DTG 17: YYYY/DDD.DDDDDDDD
|
|
210
|
+
- DTG 15: YYDDDHHMMSS.SSS
|
|
211
|
+
|
|
212
|
+
Args:
|
|
213
|
+
dtg: DTG formatted string (YYYY/DDD hhmm ss.sss)
|
|
214
|
+
time_system: System used to calculate the epoch
|
|
215
|
+
"""
|
|
216
|
+
...
|
|
217
|
+
|
|
218
|
+
def to_iso(self) -> str:
|
|
219
|
+
"""
|
|
220
|
+
Returns:
|
|
221
|
+
Epoch in ISO 8601 format (YYYY-MM-DDThh:mm:ss.sss)
|
|
222
|
+
"""
|
|
223
|
+
...
|
|
224
|
+
|
|
225
|
+
def to_dtg_20(self) -> str:
|
|
226
|
+
"""
|
|
227
|
+
Returns:
|
|
228
|
+
Epoch in DTG 20 format (YYYY/DDD HHMM SS.SSS)
|
|
229
|
+
"""
|
|
230
|
+
...
|
|
231
|
+
|
|
232
|
+
def to_dtg_19(self) -> str:
|
|
233
|
+
"""
|
|
234
|
+
Returns:
|
|
235
|
+
Epoch in DTG 19 format (YYYYMonDDHHMMSS.SSS)
|
|
236
|
+
"""
|
|
237
|
+
...
|
|
238
|
+
|
|
239
|
+
def to_dtg_17(self) -> str:
|
|
240
|
+
"""
|
|
241
|
+
Returns:
|
|
242
|
+
Epoch in DTG 17 format (YYYY/DDD.DDDDDDDD)
|
|
243
|
+
"""
|
|
244
|
+
...
|
|
245
|
+
|
|
246
|
+
def to_dtg_15(self) -> str:
|
|
247
|
+
"""
|
|
248
|
+
Returns:
|
|
249
|
+
Epoch in DTG 15 format (YYDDDHHMMSS.SSS)
|
|
250
|
+
"""
|
|
251
|
+
...
|
|
252
|
+
|
|
253
|
+
def to_time_components(self) -> TimeComponents:
|
|
254
|
+
"""
|
|
255
|
+
Returns:
|
|
256
|
+
Epoch as individual components
|
|
257
|
+
"""
|
|
258
|
+
...
|
|
259
|
+
|
|
260
|
+
def to_fk4_greenwich_angle(self) -> float:
|
|
261
|
+
"""
|
|
262
|
+
Returns:
|
|
263
|
+
Greenwich angle in radians using FK4 theory
|
|
264
|
+
"""
|
|
265
|
+
...
|
|
266
|
+
|
|
267
|
+
def to_fk5_greenwich_angle(self) -> float:
|
|
268
|
+
"""
|
|
269
|
+
Returns:
|
|
270
|
+
Greenwich angle in radians using FK5 theory
|
|
271
|
+
"""
|
|
272
|
+
...
|
|
273
|
+
|
|
274
|
+
def to_system(self, time_system: TimeSystem) -> Epoch:
|
|
275
|
+
"""
|
|
276
|
+
Convert the epoch to a different time system.
|
|
277
|
+
|
|
278
|
+
Args:
|
|
279
|
+
time_system: Desired ouput system
|
|
280
|
+
"""
|
|
281
|
+
...
|
|
282
|
+
|
|
283
|
+
def __add__(self, delta: TimeSpan) -> Epoch: ...
|
|
284
|
+
@overload
|
|
285
|
+
def __sub__(self, other: TimeSpan) -> Epoch: ...
|
|
286
|
+
@overload
|
|
287
|
+
def __sub__(self, other: Epoch) -> TimeSpan: ...
|
|
288
|
+
def __gt__(self, other: Epoch) -> bool: ...
|
|
289
|
+
def __lt__(self, other: Epoch) -> bool: ...
|
|
290
|
+
def __eq__(self, other: object) -> bool: ...
|
|
291
|
+
def __ne__(self, other: object) -> bool: ...
|
|
292
|
+
def __ge__(self, other: Epoch) -> bool: ...
|
|
293
|
+
def __le__(self, other: Epoch) -> bool: ...
|