Skip to content

Commit f36be9e

Browse files
committed
DOC: Fix ModelContainer ref
and clean up devel_io_design formatting
1 parent 9699d43 commit f36be9e

File tree

13 files changed

+181
-187
lines changed

13 files changed

+181
-187
lines changed

docs/jwst/badpix_selfcal/description.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ in the :ref:`calwebb_spec2 <calwebb_spec2>` pipeline.
1919
Input details
2020
-------------
2121
The input data must be in the form of a `~jwst.datamodels.IFUImageModel` or
22-
a `~jwst.datamodels.ModelContainer` containing exactly one
22+
a `~jwst.datamodels.container.ModelContainer` containing exactly one
2323
science exposure and any number of additional exposures.
2424
A fits or association file
2525
that can be read into one of these data models is also acceptable.

docs/jwst/outlier_detection/outlier_detection_ifu.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Integral Field Unit (IFU) Data
55

66
This module serves as the interface for applying ``outlier_detection`` to IFU
77
observations, like those taken with NIRSpec and MIRI. A :ref:`Stage 3 association <asn-level3-techspecs>`,
8-
which is loaded into a :py:class:`~jwst.datamodels.ModelContainer` object,
8+
which is loaded into a :py:class:`~jwst.datamodels.container.ModelContainer` object,
99
serves as the basic format for all processing performed by this step.
1010

1111
After launch it was discovered that the bad pixels on the MIRI detectors vary with time.

docs/jwst/outlier_detection/outlier_detection_spec.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ spectroscopic observations. The algorithm is very similar to the
88
:ref:`imaging algorithm <outlier-detection-imaging>`, and much of the same code is used.
99
Please refer to those docs for more information.
1010
A :ref:`Stage 3 association <asn-level3-techspecs>`,
11-
which is loaded into a :py:class:`~jwst.datamodels.ModelContainer` object,
12-
serves as the input and output to this step, and the :py:class:`~jwst.datamodels.ModelContainer`
11+
which is loaded into a :py:class:`~jwst.datamodels.container.ModelContainer` object,
12+
serves as the input and output to this step, and the :py:class:`~jwst.datamodels.container.ModelContainer`
1313
is converted into a :py:class:`~jwst.datamodels.library.ModelLibrary` object to allow sharing code
1414
with the imaging mode.
1515

docs/jwst/skymatch/description.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -95,9 +95,9 @@ step.
9595

9696
Identification of images that belong to the same "exposure" and therefore
9797
can be grouped together is based on several attributes described in
98-
`jwst.datamodels.ModelContainer`. This grouping is performed automatically
98+
`jwst.datamodels.container.ModelContainer`. This grouping is performed automatically
9999
in the ``skymatch`` step using the
100-
`jwst.datamodels.ModelContainer.models_grouped` property or
100+
`jwst.datamodels.container.ModelContainer.models_grouped` property or
101101
:py:meth:`jwst.datamodels.library.ModelLibrary.group_indices`.
102102

103103
However, when background across different detectors in a single "exposure"
@@ -107,7 +107,7 @@ it may be desirable to match image backgrounds independently. This can be
107107
achieved either by setting the ``image_model.meta.group_id`` attribute to a
108108
unique string or integer value for each image, or by adding the ``group_id``
109109
attribute to the ``members`` of the input ASN table - see
110-
`~jwst.datamodels.ModelContainer` for more details.
110+
`~jwst.datamodels.container.ModelContainer` for more details.
111111

112112
.. note::
113113
Group ID (``group_id``) is used by both ``tweakreg`` and ``skymatch`` steps

docs/jwst/stack_refs/description.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ multiple integrations within each exposure.
3232
It is assumed that the ``stack_refs`` step will be called from the
3333
:ref:`calwebb_coron3 <calwebb_coron3>` pipeline, which is given an ASN file as input,
3434
specifying one or more PSF target exposures.
35-
The actual input passed to the ``stack_refs`` step will be a `~jwst.datamodels.ModelContainer`
35+
The actual input passed to the ``stack_refs`` step will be a `~jwst.datamodels.container.ModelContainer`
3636
created by the :ref:`calwebb_coron3 <calwebb_coron3>` pipeline, containing a
3737
`~jwst.datamodels.CubeModel` data model for each PSF "_calints" exposure listed in the
3838
ASN file. See :ref:`calwebb_coron3 <calwebb_coron3>` for more details on the contents of

docs/jwst/stpipe/devel_io_design.rst

Lines changed: 158 additions & 165 deletions
Large diffs are not rendered by default.

jwst/master_background/expand_to_2d.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ def bkg_for_container(input_data, tab_wavelength, tab_background, allow_mos=Fals
8383
8484
Parameters
8585
----------
86-
input_data : JWST association or `~jwst.datamodels.ModelContainer`
86+
input_data : JWST association or `~jwst.datamodels.container.ModelContainer`
8787
The input science data.
8888
tab_wavelength : 1-D ndarray
8989
The wavelength column read from the 1-D background table.
@@ -99,7 +99,7 @@ def bkg_for_container(input_data, tab_wavelength, tab_background, allow_mos=Fals
9999
100100
Returns
101101
-------
102-
background : `~jwst.datamodels.ModelContainer`
102+
background : `~jwst.datamodels.container.ModelContainer`
103103
A copy of `input_data` but with the data replaced by the background,
104104
"expanded" from 1-D to 2-D.
105105
"""

jwst/master_background/master_background_step.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,14 @@ def process(self, input_data):
3333
Parameters
3434
----------
3535
input_data : `~jwst.datamodels.ImageModel`, `~jwst.datamodels.IFUImageModel`, \
36-
`~jwst.datamodels.ModelContainer`, str
36+
`~jwst.datamodels.container.ModelContainer`, str
3737
Input target datamodel(s) or association file to which master background
3838
subtraction is to be applied.
3939
4040
Returns
4141
-------
4242
result : `~jwst.datamodels.ImageModel`, `~jwst.datamodels.IFUImageModel`, \
43-
`~jwst.datamodels.ModelContainer`
43+
`~jwst.datamodels.container.ModelContainer`
4444
The background-subtracted science datamodel(s)
4545
"""
4646
with datamodels.open(input_data) as input_model:
@@ -326,11 +326,11 @@ def subtract_2d_background(source, background):
326326
327327
Parameters
328328
----------
329-
source : `~jwst.datamodels.JwstDataModel` or `~jwst.datamodels.ModelContainer`
329+
source : `~jwst.datamodels.JwstDataModel` or `~jwst.datamodels.container.ModelContainer`
330330
The input science data.
331331
background : `~jwst.datamodels.JwstDataModel`
332332
The input background data. Must be the same datamodel type as `source`.
333-
For a `~jwst.datamodels.ModelContainer`, the source and background
333+
For a `~jwst.datamodels.container.ModelContainer`, the source and background
334334
models in the input containers must match one-to-one.
335335
336336
Returns

jwst/outlier_detection/outlier_detection_step.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,15 +61,16 @@ def process(self, input_data):
6161
6262
Parameters
6363
----------
64-
input_data : asn file, `~jwst.datamodels.ModelContainer`, or \
64+
input_data : asn file, `~jwst.datamodels.container.ModelContainer`, or \
6565
`~jwst.datamodels.library.ModelLibrary`
6666
The input association.
6767
For imaging modes a ModelLibrary is expected, whereas for spectroscopic modes a
6868
ModelContainer is expected.
6969
7070
Returns
7171
-------
72-
result_models : `~jwst.datamodels.ModelContainer` or `~jwst.datamodels.library.ModelLibrary`
72+
result_models : `~jwst.datamodels.container.ModelContainer` or \
73+
`~jwst.datamodels.library.ModelLibrary`
7374
The modified input data with DQ flags set for detected outliers.
7475
"""
7576
# Open the input data, making a copy as needed.

jwst/outlier_detection/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -470,7 +470,7 @@ def flag_crs_in_models_with_resampling(
470470
471471
Parameters
472472
----------
473-
input_models : `~jwst.datamodels.ModelContainer`
473+
input_models : `~jwst.datamodels.container.ModelContainer`
474474
The input datamodels.
475475
median_data : ndarray
476476
The median data array.

0 commit comments

Comments
 (0)