Skip to content
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

Implement support for targets defined by TLE (Two-Line Element set) #566

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

michaelbaisch
Copy link
Contributor

  • Add TLETarget class that uses skyfield internally to return RA/Dec values for specific times
  • The get_skycoord() function now takes a 'time' argument because the returned SkyCoord RA/Dec values are time-dependent for TLETargets
  • get_skycoord() behavior for non-TLETargets and multiple times can be controlled with the 'backwards_compatible' argument
  • Only perform 'grid_times_targets' when targets and times are not broadcastable
  • Update the schedule table so it also displays sensible info for TLETargets
  • Update Tests

Fixes #565

For get_skycoord(), I opted for the backwards compatibility option by default. There are more details in the code, but the basic question is: Do we want to be 100% backwards compatible, or do we prefer consistent output? Having said that, everything that I've tested works well like this.

The new table looks like this:

              target                  start time (UTC)         end time (UTC)     duration (min)  type          coordinates/info         configuration
--------------------------------- ----------------------- ----------------------- -------------- ------ -------------------------------- -------------
  Capella (Alpha Aurigae) (State) 2023-08-04 10:09:25.239 2023-08-04 10:09:45.239         0.3333 RA/Dec         05h16m41.4s +45d59m52.8s            {}
                  TransitionBlock 2023-08-04 10:09:45.239 2023-08-04 10:10:05.239         0.3333                                                    []
 Sirius A (Alpha Canis Majoris A) 2023-08-04 10:10:05.239 2023-08-04 11:09:25.239        59.3333 RA/Dec           06h45m08.9s -16d42m58s            {}
                  TransitionBlock 2023-08-04 11:09:25.239 2023-08-04 11:09:45.239         0.3333                                                    []
     Castor A (Alpha Geminorum A) 2023-08-04 11:09:45.239 2023-08-04 12:06:45.239        57.0000 RA/Dec             07h34m36s +31d53m18s            {}
                  TransitionBlock 2023-08-04 12:06:45.239 2023-08-04 12:07:05.239         0.3333                                                    []
       Betelgeuse (Alpha Orionis) 2023-08-04 12:07:05.239 2023-08-04 12:16:45.239         9.6667 RA/Dec         05h55m10.3s +07d24m25.4s            {}
                  TransitionBlock 2023-08-04 12:16:45.239 2023-08-04 12:17:05.239         0.3333                                                    []
                      Unused Time 2023-08-04 12:17:05.239 2023-08-04 12:24:25.244         7.3334                                                      
           Regulus (Alpha Leonis) 2023-08-04 12:24:25.244 2023-08-04 12:59:25.244        35.0000 RA/Dec         10h08m22.3s +11d58m01.9s            {}
                  TransitionBlock 2023-08-04 12:59:25.244 2023-08-04 12:59:45.244         0.3333                                                    []
Procyon A (Alpha Canis Minoris A) 2023-08-04 12:59:45.244 2023-08-04 13:30:05.244        30.3333 RA/Dec         07h39m18.1s +05d13m29.4s            {}
                  TransitionBlock 2023-08-04 13:30:05.244 2023-08-04 13:30:45.244         0.6667                                                    []
                      Unused Time 2023-08-04 13:30:45.244 2023-08-04 15:51:25.252       140.6668                                                      
           Spica (Alpha Virginis) 2023-08-04 15:51:25.252 2023-08-04 16:05:25.252        14.0000 RA/Dec         13h25m11.6s -11d09m41.9s            {}
                  TransitionBlock 2023-08-04 16:05:25.252 2023-08-04 16:06:05.252         0.6667                                                    []
                      Unused Time 2023-08-04 16:06:05.252 2023-08-04 16:26:05.253        20.0000                                                      
                            ISS 1 2023-08-04 16:26:05.253 2023-08-04 16:26:25.253         0.3333    TLE #25544 epoch 2023-08-03 06:32:29            {}
                  TransitionBlock 2023-08-04 16:26:25.253 2023-08-04 16:26:45.253         0.3333                                                    []
                      Unused Time 2023-08-04 16:26:45.253 2023-08-04 16:31:25.253         4.6667                                                      
          Arcturus (Alpha Bootis) 2023-08-04 16:31:25.253 2023-08-04 17:05:45.253        34.3333 RA/Dec         14h15m39.7s +19d10m56.7s            {}
                  TransitionBlock 2023-08-04 17:05:45.253 2023-08-04 17:06:05.253         0.3333                                                    []
                      Unused Time 2023-08-04 17:06:05.253 2023-08-04 17:47:05.256        41.0000                                                      
                      hello world 2023-08-04 17:47:05.256 2023-08-04 18:03:45.256        16.6667 RA/Dec         18h36m56.3s +38d47m01.3s            {}
                  TransitionBlock 2023-08-04 18:03:45.256 2023-08-04 18:04:25.256         0.6667                                                    []
                            ISS 2 2023-08-04 18:04:25.256 2023-08-04 18:05:05.256         0.6667    TLE #25544 epoch 2023-08-03 06:32:29            {}
                  TransitionBlock 2023-08-04 18:05:05.256 2023-08-04 18:05:45.256         0.6667                                                    []
                      Unused Time 2023-08-04 18:05:45.256 2023-08-04 20:58:05.263       172.3335                                                      
               Vega (Alpha Lyrae) 2023-08-04 20:58:05.263 2023-08-04 21:00:25.263         2.3333 RA/Dec         18h36m56.3s +38d47m01.3s            {}
                      Unused Time 2023-08-04 21:00:25.263 2023-08-04 21:00:45.263         0.3333                                                      
                         new test 2023-08-04 21:00:45.263 2023-08-04 21:17:25.263        16.6667 RA/Dec         18h36m56.3s +38d47m01.3s            {}
                  TransitionBlock 2023-08-04 21:17:25.263 2023-08-04 21:17:45.263         0.3333                                                    []
                      Unused Time 2023-08-04 21:17:45.263 2023-08-04 22:07:45.266        50.0000                                                      
           Altair (Alpha Aquilae) 2023-08-04 22:07:45.266 2023-08-04 22:37:45.266        30.0000 RA/Dec         19h50m46.9s +08d52m05.9s            {}
                  TransitionBlock 2023-08-04 22:37:45.266 2023-08-04 22:38:05.266         0.3333                                                    []
                      Unused Time 2023-08-04 22:38:05.266 2023-08-04 23:10:45.268        32.6667                                                      
              Deneb (Alpha Cygni) 2023-08-04 23:10:45.268 2023-08-04 23:15:05.268         4.3333 RA/Dec         20h41m25.9s +45d16m49.3s            {}
                  TransitionBlock 2023-08-04 23:15:05.268 2023-08-04 23:15:45.268         0.6667                                                    []
                      Unused Time 2023-08-04 23:15:45.268 2023-08-04 23:48:05.269        32.3334                                                      
                    STARLINK-4316 2023-08-04 23:48:05.269 2023-08-04 23:48:45.269         0.6667    TLE #53471 epoch 2023-08-03 18:52:55            {}
                  TransitionBlock 2023-08-04 23:48:45.269 2023-08-04 23:49:05.269         0.3333                                                    []

* Add TLETarget class that uses skyfield internally to return RA/Dec values for specific times
* The get_skycoord() function now takes a 'time' argument because the returned SkyCoord RA/Dec values are time-dependent for TLETargets
* get_skycoord() behavior for non-TLETargets and multiple times can be controlled with the 'backwards_compatible' argument
* Only perform 'grid_times_targets' when targets and times are not broadcastable
* Update the schedule table so it also displays sensible info for TLETargets
* Update Tests
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TLE Target
1 participant