The AddMeasurementsReference converter adds a measured field reference to the passed CycleData object. This converter is only used for MBIs where online field measurements are available through the B-Train.

The converter only exists to calculate metrics when comparing measured fields and the corresponding expected field change (which field predictions should match).

Trigger

  • CycleData object.
  • resetReference trigger signal to reset the reference for a single cycle.

Logic

Save reference

The converter follows the same logic as the CalculateCorrection , except that it does not need to check the cycle for economy mode, since at this point in time, the mode of the cycle is known already.

The converter internally keeps track of the of each (LSA) cycle in a dictionary. If a reference does not exist for a cycle at trigger time, the CycleData.field_meas is taken as first reference for the corresponding CycleData.cycle key. In addition, the CycleData.cycle_timestamp is saved to know which played cycle was taken as reference.

Reset reference

When ResetReference is triggered with a cycle name, the entry in the internal reference tracker will be removed for that cycle, and a new reference will be taken the next cycle comes. This signal should only be triggered by the CalculateCorrection converter, so both references stay in sync.

Output

CycleData with all fields set, including CycleData.field_meas_ref for analysis.