-
Notifications
You must be signed in to change notification settings - Fork 77
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
get_lonlatalt doesn't give correct results for Terra / Aqua #70
Comments
Hi @espg , thanks for reporting this issue. Calling Celestrak.com is providing some historical TLEs, but I think they stop in 2004. However, if you contact them, they can probably send you the rest of the archive. |
I requested/downloaded the TLE's for both satellites from launch till the beginning of this month...I'm wondering if it makes sense to open a PR that checks for if the date is earlier than some cutoff (a month? 2020?), and use the TLE archive if that's the case, but download current from celestrak if the time is more recent. The text files aren't that large for the archive (1.7 meg's for Aqua to get all TLE's from launch to now). @mraspaud thoughts? |
I thought we already did select the closest TLE in time, but apparently not: https://github.com/pytroll/pyorbital/blob/master/pyorbital/tlefile.py#L197-L201 |
@espg good idea! |
So... I do have a fix for this, but right now it's fairly klugey. @mraspaud you're right in the public archive being incomplete, but I have requested the historic data, and have a full archive from launch to Jan. 1, 2020. I'm having some interface issues; initially I created single text files containing all the TLE's, but calling pyorbital with a TLE file argument expects just a single TLE-- if there are multiple TLE's, it will only read the first two lines. For a workaround, I took the full archive for both TERRA and AQUA, and split the TLE single text file into per-day TLE's from the archive. The celestrek archive has 3 to 4 TLE's per day, so each of these text files isn't a single TLE, but that doesn't matter, because reading the first TLE for a given day is plenty accurate, and doesn't cause the pyorbital interface to break. In short, right now there is a translator wrapper that parses the datetime object before creating the satellite query object, and translates what the correct TLE textfile is based of a year/day of year naming scheme. This isn't great. Ideally, when creating a satellite object to query, multiple TLE's could be specified (i.e., an archive of them), and at run time I'm happy to put some sweat and work into making the first and/or second solutions work and submit a PR to do this... but since the current design pattern is to fix the TLE at init of the orbital object, changing things to parse at runtime based on utc time will touch a lot of other parts of the object, so I may need some feedback and support as I work out the implementation. Thoughts? |
@espg wow, thanks for looking into this! About Orbital not looking through an archive file, this comes from the fact that it's original purpose was to work with individual TLE files, but using archives is of course a natural enhancement with I support totally. About having archive files in the pyorbital repo:
Again, thanks a lot for putting your time on this, it's highly appreciated! |
Above code yields:
(166.84878227675836, 60.28586375275336, 718.455146236583)
Terra MODIS is a nadir looking instrument, so those coordinates (or relatively close to them) should be present in the data from the sensor... but...
returns:
(-54.213318 -77.61293 -38.029873 -59.76777)
All the latitudes are in the southern hemisphere, while the pyorbital thinks that the satellite is close to the arctic circle in the northern hemisphere, so that's not great...
The text was updated successfully, but these errors were encountered: