NSCleanStep¶
- class jwst.nsclean.NSCleanStep(name=None, parent=None, config_file=None, _validate_kwds=True, **kws)[source]¶
Bases:
JwstStep
NSCleanStep: This step performs 1/f noise correction (“cleaning”) of NIRSpec images, using the “NSClean” method.
Create a
Step
instance.- Parameters:
name (str, optional) – The name of the Step instance. Used in logging messages and in cache filenames. If not provided, one will be generated based on the class name.
parent (Step instance, optional) – The parent step of this step. Used to determine a fully-qualified name for this step, and to determine the mode in which to run this step.
config_file (str path, optional) – The path to the config file that this step was initialized with. Use to determine relative path names of other config files.
**kws (dict) – Additional parameters to set. These will be set as member variables on the new Step instance.
Attributes Summary
Methods Summary
process
(input)Fit and subtract 1/f background noise from a NIRSpec image
Attributes Documentation
- class_alias = 'nsclean'¶
- spec¶
mask_spectral_regions = boolean(default=True) # Mask WCS-defined regions n_sigma = float(default=5.0) # Clipping level for outliers save_mask = boolean(default=False) # Save the created mask user_mask = string(default=None) # Path to user-supplied mask skip = boolean(default=True) # By default, skip the step
Methods Documentation
- process(input)[source]¶
Fit and subtract 1/f background noise from a NIRSpec image
- Parameters:
input (
ImageModel
,IFUImageModel
) – Input datamodel to be correctedn_sigma (float, optional) – Sigma clipping threshold to be used in detecting outliers in the image
save_mask (bool, optional) – Save the computed mask image
user_mask (None, str, or
ImageModel
) – Optional user-supplied mask image; path to file or opened datamodelmask_spectral_regions (bool, optional) – Mask regions of the image defined by WCS bounding boxes for slits/slices
- Returns:
output_model – The 1/f corrected datamodel
- Return type: