-
-
Notifications
You must be signed in to change notification settings - Fork 428
New module to query Lowell Observatory astorbDB database #3203
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
base: main
Are you sure you want to change the base?
New module to query Lowell Observatory astorbDB database #3203
Conversation
mkelley
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good and very useful in general. Some initial comments and questions to address while you continue testing.
|
Thanks @mkelley for the review. I haven't looked into it in any meaningful way yet, but I notice that there are a lot of comments on async stuff. We should remove/rework the template module as a lot has changed. E.g. there is a preference of supporting actual async/sync API and not just with the early template hackary. So I would suggest to so that, too, if the service support async, then opt into that with a keyword argument, but don't duplicate the methods with the decorator. or one PR that did the keyword approach: #3201 or the ESA modules also have a |
|
I'm not sure why the checks didn't run. @hhsieh00 You might want to try to |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3203 +/- ##
==========================================
+ Coverage 71.72% 72.03% +0.30%
==========================================
Files 235 238 +3
Lines 20253 20487 +234
==========================================
+ Hits 14527 14757 +230
- Misses 5726 5730 +4 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
mkelley
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, thanks again! I'll ask a general question for @bsipocz , this PR adds about 0.4 MB of test data. Is that OK, or should we consider reducing it?
|
|
||
| Returns | ||
| ------- | ||
| res : A dictionary holding available AstInfo data |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bsipocz is it OK that this particular _async method returns a dictionary of responses? _parse_result appropriately handles it, so the class is internally consistent.
astroquery/astorbdb/core.py
Outdated
| def _process_data_elements(self, src): | ||
| """ | ||
| internal routine to process raw data in Dict format, must | ||
| be able to work recursively |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe some additional comments could be added here to help with code maintenance. It seems to me that this is primarily about assigning units to returned values. Is there a place in the astorb documentation where the units were defined?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added some more specific comments
|
I can reduce some of the test data. Multiple objects are necessary since some have null results (e.g., main-belt asteroids don't have escape route data, while NEOs don't have family data, and relatively newly discovered asteroids don't have lightcurve, taxonomic, or albedo data), but I can reduce it to less than what's there currently. |
query code only for now; tests not written yet
Fixing some codestyle issues in core.py
fixing more codestyle issues in core.py
First complete draft of the astorbdb class including tests and documentation
removed get_raw_response lines, changed names of dynamical_family and escape_routes methods, changed OrderedDict output to regular dictionaries. Also re-ordered methods in alphabetical order. Other minor edits.
fixed dynamical_family and escape_route function names in documentation; also added astorbdb.rst to various toc files
query code only for now; tests not written yet
Fixing some codestyle issues in core.py
fixing more codestyle issues in core.py
First complete draft of the astorbdb class including tests and documentation
removed get_raw_response lines, changed names of dynamical_family and escape_routes methods, changed OrderedDict output to regular dictionaries. Also re-ordered methods in alphabetical order. Other minor edits.
query code only for now; tests not written yet
Fixing some codestyle issues in core.py
fixing more codestyle issues in core.py
This reverts commit 566ac6b.
This reverts commit 5c8298a.
This reverts commit a72f7b8.
This reverts commit 8920bf8.
This reverts commit bf119b2.
This reverts commit d56b251.
This reverts commit b51ff22.
This reverts commit 31581a6.
This reverts commit 543dea9.
This reverts commit 8bb7a92.
This reverts commit e590e4f.
This reverts commit 49700d0.
This reverts commit ca91720.
This reverts commit 5e13d19.
This reverts commit 3d9d148.
This reverts commit 70c8297.
This reverts commit f57df66.
This reverts commit 4b17fb8.
This reverts commit 756d0dc.
This reverts commit 646d3a2.
This reverts commit 804a662.
This reverts commit 1adca45.
This reverts commit 84b5feb.
This reverts commit dccfb7e.
This reverts commit e535c6d.
92a6f86 to
13be374
Compare
removed automodapi code from solarsystem version of lowellmps.rst to match other sections (e.g., jpl, imcce)
This is a new module for querying the Lowell Observatory astorbDB database (see issue #3129), specifically using REST APIs used to run their AstInfo tool (https://asteroid.lowell.edu/astinfo/). The AstInfo class in this module specifically retrieves designation, orbital element, orbit, albedo, color, taxonomy, lightcurve, dynamical family, and escape route data for asteroids catalogued in the Lowell astorbDB database.