ybatchCalc

Workspace.ybatchCalc(self: pyarts.arts._Workspace, ybatch: pyarts.arts.WorkspaceVariable | pyarts.arts.ArrayOfVector | None = self.ybatch, ybatch_aux: pyarts.arts.WorkspaceVariable | pyarts.arts.ArrayOfArrayOfVector | None = self.ybatch_aux, ybatch_jacobians: pyarts.arts.WorkspaceVariable | pyarts.arts.ArrayOfMatrix | None = self.ybatch_jacobians, ybatch_start: pyarts.arts.WorkspaceVariable | pyarts.arts.Index | None = self.ybatch_start, ybatch_n: pyarts.arts.WorkspaceVariable | pyarts.arts.Index | None = self.ybatch_n, ybatch_calc_agenda: pyarts.arts.WorkspaceVariable | pyarts.arts.Agenda | None = self.ybatch_calc_agenda, robust: pyarts.arts.WorkspaceVariable | pyarts.arts.Index | None = 0, verbosity: pyarts.arts.WorkspaceVariable | pyarts.arts.Verbosity | None = self.verbosity) None

Performs batch calculations for the measurement vector y.

We perform ybatch_n jobs, starting at index ybatch_start. (Zero based indexing, as usual.) The output array ybatch will have ybatch_n elements. Indices in the output array start with zero, independent of ybatch_start.

The method performs the following:

  1. Sets ybatch_index = ybatch_start.

  2. Performs a-d until ybatch_index = ybatch_start + ybatch_n.
    1. Executes ybatch_calc_agenda.

    2. If ybatch_index = ybatch_start, resizes ybatch based on ybatch_n and length of y.

    3. Copies y to ybatch_index - ybatch_start of ybatch.

    4. Adds 1 to ybatch_index.

Beside the ybatch_calc_agenda, the WSVs ybatch_start and ybatch_n must be set before calling this method. Further, ybatch_calc_agenda is expected to produce a spectrum and should accordingly include a call of yCalc() (or asimilar method).

The input variable ybatch_start is set to a default of zero.

Jacobians are also collected, and stored in output variable ybatch_jacobians. (This will be empty if yCalc() produces empty Jacobians.)

See the user guide for further practical examples.

Author(s): Stefan Buehler

Parameters:
  • ybatch (ArrayOfVector, optional) – Batch of spectra. See ybatch, defaults to self.ybatch [OUT]

  • ybatch_aux (ArrayOfArrayOfVector, optional) – Data auxilary to ybatch. See ybatch_aux, defaults to self.ybatch_aux [OUT]

  • ybatch_jacobians (ArrayOfMatrix, optional) – All the Jacobians associated with ybatch. See ybatch_jacobians, defaults to self.ybatch_jacobians [OUT]

  • ybatch_start (Index, optional) – Start index for ybatchCalc(). See ybatch_start, defaults to self.ybatch_start [IN]

  • ybatch_n (Index, optional) – Number of batch cases for ybatchCalc(). See ybatch_n, defaults to self.ybatch_n [IN]

  • ybatch_calc_agenda (Agenda, optional) – Calculations to perform for each batch case. See ybatch_calc_agenda, defaults to self.ybatch_calc_agenda [IN]

  • robust (Index, optional) – A flag with value 1 or 0. If set to one, the batch calculation will continue, even if individual jobs fail. In that case, a warning message is written to screen and file (out1 output stream), and the y Vector entry for the failed job in ybatch is left empty. Defaults to 0 [IN]

  • verbosity (Verbosity) – ARTS verbosity. See verbosity, defaults to self.verbosity [IN]