pyhgf.updates.vectorized.volatile.vectorized_layer_volatility_posterior_ehgf#

pyhgf.updates.vectorized.volatile.vectorized_layer_volatility_posterior_ehgf(layer, params, time_step, max_posterior_precision=10000000000.0)[source]#

EHGF volatility-level posterior update (mean first, then safe precision).

The eHGF update differs from the standard update in that it updates the mean first using the expected precision as an approximation, and then applies the safe precision update: the effective precision is recomputed from the just-updated posterior mean and the increment is floored at zero.

This is the vectorized equivalent of pyhgf.updates.posterior.volatile.volatile_node_posterior_update_ehgf.volatile_node_posterior_update_ehgf().

Parameters:
  • layer (LayerState) – Current layer state with volatility_prediction_error set.

  • params (LayerParams) – Layer parameters (provides volatility_coupling and tonic_volatility).

  • time_step (float) – Current time step (needed to recompute the effective precision and to reconstruct the pre-prediction variance).

  • max_posterior_precision (float) – Upper bound applied to the volatility-level posterior precision. Default 1e10.

Returns:

Updated layer state with precision_vol and mean_vol set.

Return type:

LayerState