Combine Frames

Overview

Combines a stack of frames.

Class: CombineFramesStep

Algorithm

A data cube is created from the input frames. The cube is then reduced according to the input argument method. If method='sigma_clip', bad pixels are iteratively flagged before reduction. Currently only the sigma clipping method only implements cenfunc=’median’ and stdfunc=’mad_std’.

The error is calculated in one of two ways:

  1. error_calc='measure' : The error is calculated from the standard deviation of the values of the input frames.

  2. error_calc='propagate' : The error is calculated from the propagation of the errors of the input frames:

    \[\sigma = \big( \sum_i \sigma_i^{-2} \big)^{-1/2}\]

where \(\sigma\) is the error of the combined frame and \(\sigma_i\) is the error of the input frames.

Arguments

inputlist[str | LigerIRISDataModel ]

The input data to combine.

methodstr
Method for combining the frames:
  • ‘mean’: Unweighted mean.

  • ‘wmean’: Weighted mean.

  • ‘median’: Unweighted median.

  • ‘wmedian’: Weighted median.

  • ‘sigma_clip’: Sigma clipping, see parameters below. Currently, only cenfunc=’median’ and stdfunc=’mad_std’ are supported.

do_sigma_clipbool

Whether to apply sigma clipping. Sigma clipping is performed using the biweight location and biweight midvariance (both unweighted), regardless of the method parameter.

sigma_thresh_lowfloat

Number of standard deviations below the central value to flag as outliers.

sigma_thresh_highfloat

Number of standard deviations above the central value to flag as outliers.

thresh_lowfloat or None

Absolute lower bound for outlier rejection. Values below this threshold will be excluded.

thresh_highfloat or None

Absolute upper bound for outlier rejection. Values above this threshold will be excluded.

num_mask_lowint or None

Maximum number of low-end outliers to mask per batch.

num_mask_highint or None

Maximum number of high-end outliers to mask per batch.

min_batch_sizeint

Minimum number of frames per batch required to apply sigma clipping.

maxitersint

Maximum number of iterations for the sigma clipping process.

error_calcstr
Method for calculating the output error:
  • ‘measure’: Estimate from data dispersion.

  • ‘propagate’: Propagate errors from input values.

Subarrays

TBD.

Calibration Files

None