Skip to content

Commit

Permalink
Now fixed style lint test
Browse files Browse the repository at this point in the history
  • Loading branch information
BrunoSanchez committed Sep 14, 2023
1 parent 968dd43 commit 35269ac
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions python/lsst/ip/diffim/subtractImages.py
Original file line number Diff line number Diff line change
Expand Up @@ -582,11 +582,11 @@ def finalize(self, template, science, difference, kernel,
deltaMaskPlaneTemplate = 2**(diffInjectedTemplateMaskPlane - templateFakeMaskPlane)

# get the arrays from the template and science that are flagged as FAKE
injectedScienceMaskArray = (science.mask.array & scienceFakeBitMask) * deltaMaskPlaneScience
injectedTemplateMaskArray = (template[bbox].mask.array & templateFakeBitMask) * deltaMaskPlaneTemplate
injScienceMaskArray = (science.mask.array & scienceFakeBitMask) * deltaMaskPlaneScience
injTemplateMaskArray = (template[bbox].mask.array & templateFakeBitMask) * deltaMaskPlaneTemplate

mask.array |= injectedScienceMaskArray
mask.array |= injectedTemplateMaskArray
mask.array |= injScienceMaskArray
mask.array |= injTemplateMaskArray

# We have cleared the template mask plane, so copy the mask plane of
# the image difference so that we can calculate correct statistics
Expand Down Expand Up @@ -745,7 +745,6 @@ def _checkMask(mask, sources, badMaskPlanes):
maskPlane for maskPlane in badMaskPlanes if maskPlane in mask.getMaskPlaneDict().keys()
]

#badPixelMask = lsst.afw.image.Mask.getPlaneBitMask(badMaskPlanes)
badPixelMask = mask.getPlaneBitMask(setBadMaskPlanes)

xv = np.rint(sources.getX() - mask.getX0())
Expand Down

0 comments on commit 35269ac

Please sign in to comment.