Open clmuddjr opened 3 years ago
After running some testing, it happens to be some aspect of specific satellites in the science celestral tle file.
I began an 'x' count had the routine stop at 5 and it worked. I did the same for additional levels and eventually obtained an error at 829.
I then had the routine skip 829 which it did. But, it stopped at 831. After a few more satellites, I wanted to see what line caused the issue and determined that it broke at the following line:
orb2=Orbital(abra, tle_file=satfilename)
The satellites that do not work so far are:
POLAR 1 23802U 96013A 20295.99938125 .00000118 00000-0 00000-0 0 9998 2 23802 78.7088 248.2197 6205894 279.1057 19.6545 1.29846457118054
XMM-NEWTON 1 25989U 99066A 20297.18987583 -.00000114 00000-0 00000-0 0 9999 2 25989 71.0622 317.6914 6934313 92.2856 359.7978 0.50131985 27026
CLUSTER II-FM7 (SAMBA)
1 26410U 00041A 20298.26891925 .00000128 00000-0 00000-0 0 9992
2 26410 132.1394 342.6239 4553022 186.5114 0.7721 0.44217239 11151
CLUSTER II-FM6 (SALSA)
1 26411U 00041B 20298.35099240 .00000002 00000-0 00000-0 0 9994
2 26411 132.3246 344.0376 5911886 192.0067 0.8331 0.44249497 11197
I noticed a pattern in field 11 for Drag Term:
in that they all were 00000-0:
So, I wrote this code rather than adding each specific satellite and it completed without issue:
line2_str = str(line2)
dragterm = line2_str[54:59]
if dragterm == "00000":
print (line1, dragterm)
continue
@clmuddjr thanks for reporting this issue!
I think the Deep space error comes when trying to use TLEs for computing geostationary or deep space orbits, with pyorbital doesn't support yet.
For polar satellites, you shouldn't get this problem. What are the orbits of the satellites you are working on?
If someone wants to dive into a PR for deep space computations: deep space initialisation (https://github.com/pytroll/pyorbital/blob/master/pyorbital/orbital.py#L779-L780) should follow page 85 of https://celestrak.com/publications/AIAA/2006-6753/AIAA-2006-6753-Rev3.pdf
and propagation (https://github.com/pytroll/pyorbital/blob/master/pyorbital/orbital.py#L779-L780) should implement the beginning of page 88 (and the functions called therein)
Other places marked with if (satrec.method == 'd')
need to be implemented too.
Some of the deep space test cases are already included in test_aiaa.py
, but just skipped for now: https://github.com/pytroll/pyorbital/blob/master/pyorbital/tests/test_aiaa.py#L128-L130
Dear people:
I want to run through a TLE file and calculate the coordinates of each satellite for a period of time (right now, datetime will only allow 60 seconds, but would like to run it longer).
At first, using Orbital from PyOrbital, I obtained an error that certain satellites could not be found in the TLE file I specified. Then, I realized that Orbital may have been pulling from the Internet (Celestrak) given I had not identified a tle_file. Then, after modifying Orbital, I obtained an error that "Deep space calculations not supported."
This is the code:
f.close()
Problem description
As mentioned above, I get an error for Deep space calculations not supported just from running the TLE file. And, unless I am missing something, I do not see how it happens to be a deep space calculation where I am just trying to calculate each satellites individual coordinates over 60 seconds.
Expected Output
It should just complete the calculations and provide me with two lists: filter_sat_coords and sat_sec_list. When I run it using a single user-selected satellite known to be in the tle file (HST), it works. This code works:
With the result:
As does:
With the result:
Actual Result, Traceback if applicable
However, when I run the code at the top using "line1" for the satname from the TLE file, it gives me the error.
Could it be something with this line of code and trying to do the iteration:
for line1,line2,line3 in itertools.zip_longest([r]3):
and then using line1 for the satellite name?
For, when I change "line1" to "sat1" again the code, specifically:
orb2=Orbital(sat1, tle_file=satfilename)
it works.
Could it be the number of satellites or calculations?
Versions of Python, package at hand and relevant dependencies
3.8.6 | packaged by conda-forge | (default, Dec 22 2020, 10:15:24) [Clang 11.0.0 ]
Thank you for reporting an issue !