KnownHazard

class Python_modules.mmcomplexity.KnownHazard(stimulus_object, sources_prior=(0.5, 0.5))

Bases: Python_modules.mmcomplexity.BinaryDecisionMaker

Binary decision maker which is an ideal observer who knows the true hazard rate value and assumes it fixed.

Methods Summary

process([observations, hazard, filter_step, …])

This is where the bulk of the decision process occurs.

Methods Documentation

process(observations=None, hazard=None, filter_step=0, target='source')

This is where the bulk of the decision process occurs. Observations are converted into a decision variable.

For now, only the log posterior odds of the sources is computed, and hazard rate is assumed fixed.

Args:

observations (list): sequence of perceived sound locations. If None, self.observations is used hazard: hazard rate, if None, the one from the stimulus_object attribute is fetched filter_step (int): point in time on which the inference happens. 0 corresponds to present, 1 to prediction.

When 0, the first decision happens after the first observation is made, when 1, the first decision (prediction) is made before the first observation is made.

target (str): must be either ‘source’ or ‘sound’

Returns:

generator object that yields (log posterior odds, decisions)