webbpsf icon indicating copy to clipboard operation
webbpsf copied to clipboard

add functions to download WFSC WL image data

Open mperrin opened this issue 3 months ago • 3 comments

Sometimes it's useful to download the weak lens image data. This PR adds to mast_wss some functions for doing so, either by specifying a WFSC program ID and observation number, or else by default just getting the most recent WFSC image data. The download_wfsc_images function retrieves the level-3 wfscmb data products from MAST and downloads into the current working directory.

This is probably less useful to general users of webbpsf, and is intended mainly as a convenience for us on the mission team. But can also be useful for expert-level external users too, in some select cases. In any case I think this fits in well as part of the mast_wss submodule.

(For right now, defaults to only downloading from NRCA3, but this is a user-selectable parameter in case data from one of the other detectors is wanted)

mperrin avatar Apr 05 '24 15:04 mperrin

Hello @mperrin, Thank you for updating !

Line 18:1: E266 too many leading '#' for block comment Line 47:72: E703 statement ends with a semicolon Line 61:1: E266 too many leading '#' for block comment Line 86:9: E265 block comment should start with '# ' Line 91:27: E226 missing whitespace around arithmetic operator Line 104:23: E226 missing whitespace around arithmetic operator Line 105:23: E701 multiple statements on one line (colon) Line 113:27: E701 multiple statements on one line (colon) Line 204:19: E701 multiple statements on one line (colon) Line 208:19: E701 multiple statements on one line (colon) Line 212:19: E701 multiple statements on one line (colon) Line 218:9: E122 continuation line missing indentation or outdented Line 219:19: E701 multiple statements on one line (colon) Line 221:57: E251 unexpected spaces around keyword / parameter equals Line 221:59: E251 unexpected spaces around keyword / parameter equals Line 225:1: E266 too many leading '#' for block comment Line 225:1: E303 too many blank lines (3) Line 227:1: E302 expected 2 blank lines, found 3 Line 298:1: E266 too many leading '#' for block comment Line 374:1: E302 expected 2 blank lines, found 1 Line 384:13: E128 continuation line under-indented for visual indent Line 392:1: E302 expected 2 blank lines, found 1 Line 462:5: E265 block comment should start with '# ' Line 463:5: E265 block comment should start with '# ' Line 469:33: E231 missing whitespace after ',' Line 477:5: E265 block comment should start with '# ' Line 483:23: E701 multiple statements on one line (colon) Line 493:23: E701 multiple statements on one line (colon) Line 558:40: E701 multiple statements on one line (colon) Line 590:25: E203 whitespace before ':' Line 590:39: E203 whitespace before ':' Line 592:1: E302 expected 2 blank lines, found 1 Line 632:9: E123 closing bracket does not match indentation of opening bracket's line Line 697:13: E126 continuation line over-indented for hanging indent Line 697:39: E261 at least two spaces before inline comment Line 700:12: E126 continuation line over-indented for hanging indent Line 704:5: E303 too many blank lines (3) Line 706:11: E128 continuation line under-indented for visual indent Line 707:10: E124 closing bracket does not match visual indentation Line 744:24: E231 missing whitespace after ':' Line 748:17: E124 closing bracket does not match visual indentation Line 756:5: E303 too many blank lines (2) Line 756:41: E231 missing whitespace after ',' Line 768:5: E303 too many blank lines (2) Line 771:28: E201 whitespace after '(' Line 771:33: E226 missing whitespace around arithmetic operator Line 773:16: E225 missing whitespace around operator Line 776:1: E302 expected 2 blank lines, found 1 Line 776:39: E241 multiple spaces after ',' Line 801:5: E303 too many blank lines (2) Line 802:13: E225 missing whitespace around operator Line 805:5: E265 block comment should start with '# '

Comment last updated at 2024-04-08 16:51:17 UTC

pep8speaks avatar Apr 05 '24 15:04 pep8speaks

FYI to @grbrady. (This feature for webbpsf was partially inspired by wanting an quick tool to download more WL data, for testing out with stpr)

mperrin avatar Apr 05 '24 15:04 mperrin

Codecov Report

Attention: Patch coverage is 13.15789% with 33 lines in your changes are missing coverage. Please review.

Project coverage is 59.20%. Comparing base (c5ea52d) to head (b536111). Report is 6 commits behind head on develop.

:exclamation: Current head b536111 differs from pull request most recent head 4fd765f. Consider uploading reports for the commit 4fd765f to get more accurate results

Files Patch % Lines
webbpsf/mast_wss.py 13.15% 33 Missing :warning:
Additional details and impacted files
@@             Coverage Diff             @@
##           develop     #827      +/-   ##
===========================================
- Coverage    59.91%   59.20%   -0.71%     
===========================================
  Files           16       16              
  Lines         6865     6955      +90     
===========================================
+ Hits          4113     4118       +5     
- Misses        2752     2837      +85     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar Apr 05 '24 15:04 codecov[bot]