paraqeet.measurement.measurement.NormalizableMeasurement#

class paraqeet.measurement.measurement.NormalizableMeasurement#

Bases: Measurement

An abstract class for measurements providing normalized scalar value.

Subclasses must implement the calculate_normalized_scalar() method which would return a measured value between 0 and 1.

__init__()#

Methods

__init__()

calculate_normalized_scalar(times)

Measure the normalized observable.

measure(times)

Measure the observable and returns the value.

abstract calculate_normalized_scalar(times)#

Measure the normalized observable.

Returns a single scalar value between 0 and 1. This function must be implemented by subclasses.

Parameters:
  • times (Array) – One-dimensional vector of timestamps.

  • projection (Array | None) – The projector matrix to restrict the operator.

Returns:

Returns a float if implemented by a subclass.

Return type:

float

abstract measure(times)#

Measure the observable and returns the value.

Parameters:
  • times (Array) – One-dimensional vector of timestamps.

  • projector (Array | None) – The projector matrix to restrict the operator.

Returns:

This abstract method must return an Array or a float when implemented by subclasses. Might return multiple values.

Return type:

Array or float