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

RA.769 table (protection thresholds) has poor documentation and buggy unit support #6

Closed
bwinkel opened this issue Feb 19, 2019 · 0 comments · Fixed by #8
Closed

RA.769 table (protection thresholds) has poor documentation and buggy unit support #6

bwinkel opened this issue Feb 19, 2019 · 0 comments · Fixed by #8

Comments

@bwinkel
Copy link
Owner

bwinkel commented Feb 19, 2019

The protection.ra769_limits function returns an astropy.table.Table object containing RAS threshold values with units attached. Unfortunately, there was a bug in the Column implementation of Table, which allowed logarithmic units to be set, but one could not retrieve them properly (the .unit property works, but not .quantity). This has been fixed recently (see astropy/astropy#8424), but was not released yet. Once the new astropy version is released, the pycraf documentation should be updated to highlight the fact.

The documentation regarding the protection.ra769_limits should be improved anyway, recommending to actually make use of the units in the returned Table object. Many people (myself included) often just use the numbers and attach the units manually. Another option could be to return a astropy.table.QTable directly, the rows of which are astropy.units.Quantity objects.

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 a pull request may close this issue.

1 participant