Skip to main content

HeadSamplingMissScenario

Agents scenarios · Implementation: mlsysim/engine/scenario_definitions/agents.py.

Construct this scenario with keyword inputs. The fields below show the types and defaults declared by this class.

Head sampling keeps each trial with retention_probability, decided before its outcome; a failure mode that occurs occurrences times leaves no detailed trace with miss.

Notes

Equation: miss is the worked quantity; each property below states its equation and units.

Assumptions: Each failure occurrence is independently retained with the same head-sampling probability.

Excludes: Outcome-dependent sampling and correlated retention decisions.

References

Derivation: The scenario binds declared inputs to calc_independent_success. Those implementations document their derivations and sources.

Examples

Execute the registered worked inputs; this is a modeled calculation.

>>> from mlsysim import Scenarios
>>> case = Scenarios.RareFailureUnderHeadSampling
>>> value = case.miss
>>> round(value, 3)
0.59

Attributes

Name Description
miss Probability that independent head sampling retains none of the failure occurrences.
occurrences
retention_probability

retention_probability

Type: float.

Declared default: required.

occurrences

Type: int.

Declared default: required.

miss

engine.scenario_types.HeadSamplingMissScenario.miss

Probability that independent head sampling retains none of the failure occurrences.

(1 - p)^n: no occurrence retained, the complement of calc_independent_success.

Equation: return 1 - calc_independent_success(self.retention_probability, self.occurrences)

Back to top