Skip to content
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

JP-3913: Add sirskernel to refpix reference types #9261

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changes/9261.refpix.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add 'sirskernel' to the reference types for the step, so that 'override_sirskernel' is available as a step parameter.
4 changes: 4 additions & 0 deletions docs/jwst/references_general/references_general.rst
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,8 @@ documentation on each reference file.
| | :ref:`READNOISE <readnoise_reffile>` |
+-------------------------------------------------------+--------------------------------------------------+
| :ref:`refpix <refpix_step>` | :ref:`REFPIX <refpix_reffile>` |
+ +--------------------------------------------------+
| | :ref:`SIRSKERNEL <sirskernel_reffile>` |
+-------------------------------------------------------+--------------------------------------------------+
| :ref:`reset <reset_step>` | :ref:`RESET <reset_reffile>` |
+-------------------------------------------------------+--------------------------------------------------+
Expand Down Expand Up @@ -282,6 +284,8 @@ documentation on each reference file.
+--------------------------------------------------+-------------------------------------------------------+
| :ref:`SFLAT <sflat_reffile>` | :ref:`flatfield <flatfield_step>` |
+--------------------------------------------------+-------------------------------------------------------+
| :ref:`SIRSKERNEL <sirskernel_reffile>` | :ref:`refpix <refpix_step>` |
+--------------------------------------------------+-------------------------------------------------------+
| :ref:`SPECWCS <specwcs_reffile>` | :ref:`assign_wcs <assign_wcs_step>` |
+--------------------------------------------------+-------------------------------------------------------+
| :ref:`SUPERBIAS <superbias_reffile>` | :ref:`superbias <superbias_step>` |
Expand Down
25 changes: 25 additions & 0 deletions docs/jwst/references_general/sirskernel_reffile.inc
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
.. _sirskernel_reffile:

SIRSKERNEL Reference File
-------------------------

:REFTYPE: SIRSKERNEL
:Data model: `~jwst.datamodels.SIRSKernelModel`

The SIRSKERNEL reference file contains Fourier coefficients for an
optimized convolution kernel, used for correcting 1/f noise from
detector reference pixels.

.. include:: ../includes/standard_keywords.inc

Reference File Format
+++++++++++++++++++++
SIRSKERNEL reference files are in ASDF format. They contain a dictionary with
keys corresponding to lower-case detector names. Each detector entry contains
two arrays, `gamma` and `zeta`, which contain the complex Fourier coefficients
required to apply the Simple Improved Reference Subtraction (SIRS) algorithm
for reference pixel correction.

The first dimension of the array holds the sector index (amplifier output,
4 per detector). The second dimension matches the height of the sector, plus one.
The data type for both arrays is `complex64`.
9 changes: 6 additions & 3 deletions docs/jwst/refpix/reference_files.rst
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
Reference Files
===============

The ``refpix`` step uses a REFPIX reference file, but only when
The ``refpix`` step uses a REFPIX reference file when
processing NIRSpec exposures that have been acquired using an IRS2
readout pattern. No other instruments or exposure modes require a
reference file for this step.
readout pattern.

For other full-frame NIR instruments and modes, when the optional SIRS algorithm
is selected, the ``refpix`` step uses a SIRSKERNEL reference file.

.. include:: ../references_general/refpix_reffile.inc
.. include:: ../references_general/sirskernel_reffile.inc
2 changes: 1 addition & 1 deletion jwst/refpix/refpix_step.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class RefPixStep(Step):
halfwidth = integer(default=30) # Half-width of convolution kernel to build
""" # noqa: E501

reference_file_types = ['refpix']
reference_file_types = ['refpix', 'sirskernel']

def process(self, step_input):

Expand Down