circuit_knitting.utils.metrics.HOP¶
- HOP(target, obs)[source]¶
Compute the Heavy Output Probability (HOP).
The HOP is an important metric for quantum volume experiments and is defined at the probability that one measures a bitstring above the median target probability.
Deprecated since version 0.7.0: The function
circuit_knitting.utils.metrics.HOP()
is deprecated as of circuit-knitting-toolbox 0.7.0. It will be removed no sooner than CKT v0.8.0.Example: >>> HOP(np.array([0.1, 0.1, 0.3, 0.5]), np.array([0.25, 0.25, 0.25, 0.25])) 0.5
- Parameters:
target – The target feature vector
obs – The actually observed feature vector
- Returns:
The computed HOP