Repository navigation
Use the MPC ObsCodes list for observatory locations - #22
Merged
Merged
Conversation
…BITAL spacecraft model. Space observatories are the entries without parallax constants; alphanumeric codes map to integers as I11 -> 1811. Fixes OSSOS#20. Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #20.
observatories.datis now the current MPC list (https://minorplanetcenter.net/iau/lists/ObsCodes.html, 2729 codes), and the reader parses its fixed-column layout (east longitude, rho cos φ', rho sin φ'). As in the MPC list, space observatories are the entries with no longitude/parallax constants. TheOBSCODE_ORBITALthreshold is gone, which removes:os393.hst/pn70.hsthack, which read a file from the working directory and crashed if it was missing.Other changes:
obscode_from_string, used for MPC lines and free-format input files) and Python (mp_ephem.ephem.obscode_to_int, used bypredict/predict_helio), soobs_code='T14'works.is_visibletreats these as always visible instead of exiting.OBSCODE_SSBARYmoves from 0 to -2 because MPC code 000 is Greenwich.MAX_SITESwas 400).ORBIT_OBSERVATORIESfiles in the old colon format now stop with a clear error instead of being misread. Users with custom files will need to switch to the MPC layout, and old integer codes such as 1811 should be written as I11.Validation:
Made with Cursor