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
DM-7886: Use astropy rather than pyfits #47
Conversation
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
# estimate it from the pixel values. | ||
# Find the peak location in the high end part the pixel values' | ||
# histogram and set the saturation level at safe * (peak location) | ||
# where safe is a configurable parameter (typically 0.95) |
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.
I thought only doc strings were required to be short so I'm a bit surprised by this change. Not that it's a problem, but I hope we won't be expected to do this for all our code.
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.
We have to include comments because PEP8 includes comments and docstrings in the definition and pycodestyle implements the PEP8 rule. When we enable max docstring rule in flake8 the rule can't tell the difference. The developer guide does specify comments and docstrings.
@@ -1,7 +1,6 @@ | |||
[flake8] | |||
max-line-length = 110 | |||
ignore = E133, E226, E228, E266, N802, N803, N806 | |||
# TODO: remove E266 when Task documentation is converted to rst in DM-14207. | |||
ignore = E133, E226, E228, N802, N803, N806 |
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.
Good catch. (I wonder if CfhtIsrTask should have the usual docs, but adding them is clearly out of scope, so I agree with removing the unneeded exclusion).
@@ -2,6 +2,7 @@ setupRequired(daf_persistence) | |||
setupRequired(obs_base) | |||
setupRequired(meas_algorithms) | |||
setupRequired(pipe_tasks) | |||
setupRequired(astropy) |
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.
I forgot to check for this in the other pyfits->astropy pull requests I reviewed.
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.
I've only been adding if the code in bin.src or python/ uses astropy. Not if the examples do.
No description provided.