AmiAnalyzeStep
- class jwst.ami.ami_analyze_step.AmiAnalyzeStep(name=None, parent=None, config_file=None, _validate_kwds=True, **kws)[source]
Bases:
JwstStep
Performs analysis of an AMI mode exposure by applying the LG algorithm.
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 or pathlib.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
Read user-input affine transform from ASDF file.
Read bandpass from asdf file and use it to override the default.
process
(input_data)Perform analysis of an AMI mode exposure by applying the LG algorithm.
save_model
(model, *args, **kwargs)Override save_model to change suffix based on list of results.
Attributes Documentation
- class_alias = 'ami_analyze'
- reference_file_types: ClassVar = ['throughput', 'nrm']
- spec
oversample = integer(default=3, min=1) # Oversampling factor rotation = float(default=0.0) # Rotation initial guess [deg] psf_offset = string(default='0.0 0.0') # PSF offset values to use to create the model array rotation_search = string(default='-3 3 1') # Rotation search parameters: start, stop, step bandpass = string(default=None) # ASDF file containing array to override filter/source usebp = boolean(default=True) # If True, exclude pixels marked DO_NOT_USE from fringe fitting firstfew = integer(default=None) # If not None, process only the first few integrations chooseholes = string(default=None) # If not None, fit only certain fringes e.g. ['B4','B5','B6','C2'] affine2d = string(default='commissioning') # ASDF file containing user-defined affine parameters OR 'commssioning' run_bpfix = boolean(default=True) # Run Fourier bad pixel fix on cropped data
Methods Documentation
- override_affine2d()[source]
Read user-input affine transform from ASDF file.
Makes an Affine2d object (see utils.Affine2D class). Input should contain mx,my,sx,sy,xo,yo,rotradccw.
- Returns:
affine2d – User-defined affine transform
- Return type:
Affine2d object
- override_bandpass()[source]
Read bandpass from asdf file and use it to override the default.
Expects an array of [effstims, wave_m] (i.e. np.array((effstims,wave_m)).T) stored as ‘bandpass’ in asdf file, where effstims are normalized countrates (unitless) and wave_m are the wavelengths across the filter at which to compute the model (meters).
- Returns:
bandpass – Array of [countrates, wavelengths]
- Return type:
array
- process(input_data)[source]
Perform analysis of an AMI mode exposure by applying the LG algorithm.
- Parameters:
input_data (str or datamodel) – Input file name or datamodel
- Returns:
oifitsmodel (AmiOIModel object) – AMI tables of median observables from LG algorithm fringe fitting in OIFITS format
oifitsmodel_multi (AmiOIModel object) – AMI tables of observables for each integration from LG algorithm fringe fitting in OIFITS format
amilgmodel (AmiLGFitModel object) – AMI cropped data, model, and residual data from LG algorithm fringe fitting