Skip to content

Commit

Permalink
Fix a call to interpret_bits in coron3 (#5914)
Browse files Browse the repository at this point in the history
* fix a call to interpret_bits in coron3

* add change log entry
  • Loading branch information
nden authored Mar 26, 2021
1 parent 5f32edd commit 06e021f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ datamodels
- Moved functions in ``dqflags`` and ``dynamic_mask`` to ``stcal`` [#5898]

- API change - ``stcal.dqflags.interpret_bit_flags`` and ``stcal.dynamicdq.dynamic_mask``
now require the ``mnemonic_map`` as input. [#5898]
now require the ``mnemonic_map`` as input. [#5898, #5914]

extract_2d
----------
Expand Down
6 changes: 4 additions & 2 deletions jwst/coron/align_refs_step.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
""" Replace bad pixels and align psf image with target image."""

from jwst.datamodels.dqflags import interpret_bit_flags
from stcal.dqflags import interpret_bit_flags

from jwst.datamodels.dqflags import pixel

from ..stpipe import Step
from .. import datamodels
Expand Down Expand Up @@ -50,7 +52,7 @@ def process(self, target, psf):

# Get the bit value of bad pixels. A value of 0 treats all pixels as good.
bad_bitvalue = self.bad_bits
bad_bitvalue = interpret_bit_flags(bad_bitvalue)
bad_bitvalue = interpret_bit_flags(bad_bitvalue, mnemonic_map=pixel)
if bad_bitvalue is None:
bad_bitvalue = 0

Expand Down

0 comments on commit 06e021f

Please sign in to comment.