Skip to content

Commit

Permalink
Merge branch 'master' into twilights
Browse files Browse the repository at this point in the history
  • Loading branch information
ajmejia committed Feb 1, 2024
2 parents 9e93bcc + 56ea797 commit 317331d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion python/lvmdrp/functions/imageMethod.py
Original file line number Diff line number Diff line change
Expand Up @@ -3377,7 +3377,10 @@ def detrend_frame(
log.info("subtracting master dark")
elif in_dark and in_pixelflat:
log.info("subtracting master dark and dividing by master pixelflat")
detrended_img = (bcorr_img - mdark_img.convertUnit(to=bcorr_img._header["BUNIT"])) / mflat_img

detrended_img = (bcorr_img - mdark_img.convertUnit(to=bcorr_img._header["BUNIT"]))
# NOTE: this is a hack to avoid the error propagation of the division in Image
detrended_img = detrended_img / mflat_img._data

# propagate pixel mask
log.info("propagating pixel mask")
Expand Down

0 comments on commit 317331d

Please sign in to comment.