eradiate.pipelines.AggregateCKDQuad#

class eradiate.pipelines.AggregateCKDQuad(measure, binset, var='img')[source]#

Bases: PipelineStep

Compute CKD quadrature.

In CKD modes, this pipeline step aggregates spectral data and evaluates the selected quadrature rule. The following updates to the input data are expected:

  • the g dimension is dropped;

  • the bin dimension is renamed w;

  • the bin coordinate persists and is indexed by w;

  • a w coordinate is created and contains the central wavelength of each bin;

  • a bin_wmin (resp. bin_wmax) coordinate is created and contains the lower (resp. upper) spectral bound of each bin;

  • the dataset is reordered by ascending w values.

Parameters:
  • measure (Measure) – Measure from which the processed data was obtained.

  • binset (BinSet) – Bin set.

  • var (str, default: "img") – Name of the variable for which CKD quadrature computation is to be performed.

Fields:
  • measure (Measure) – Measure from which the processed data was obtained.

  • binset (BinSet) – Bin set.

  • var (str) – Name of the variable for which CKD quadrature computation is to be performed.

Notes

  • The spp variable is averaged on the g dimension.

  • In non-CKD modes, this step is a no-op.

transform(x)[source]#

Apply the pipeline step to a given data.

Parameters:

x – Data to process.

Returns:

xt – Processed data.