SearcharxivSearch

arXiv subjects

Chris Mathys

Publications and source records attributed to Chris Mathys.

3 recordsLinked to original sources

Closed-form predictive coding via hierarchical Gaussian filters

Predictive coding (PC) offers a local and biologically grounded alternative to backpropagation in the training of artificial neural networks, yet to date, it remains slower, and performance degrades sharply as network depth increases. We trace both problems to a single simplification: current PC networks fix the precision matrix to the identity, discarding precision-weighted prediction errors that the variational derivation requires to be fast, local, and Bayesian. We close this gap by expressing predictive coding networks as deep hierarchical Gaussian filters (HGFs) and restore precision-weighted message passing, yielding dynamic uncertainty estimates and Hebbian-compatible update rules at every layer. The resulting networks can simultaneously learn activations, weights, and precisions under a single free-energy objective, with no global error signal, and resolve inference without requiring iterations or automatic differentiation. On FashionMNIST, our solution approaches backpropagation in epoch-level wall-clock cost while converging in fewer epochs, and outperforms it on online, data efficiency, and concept-drift tasks. We thus establish that closed-form variational inference with online precision learning provides a tractable foundation for deep predictive coding networks, retaining biological and interpretative advantages, without requiring iterative relaxation or global error signals.

cs.LG

The Role of Affect and Priors in the Generation of Hallucinations in Early Psychosis

Background: Stress and negative affect play significant roles in developing psychosis. Bayesian analyses applied to the conditioned hallucinations (CH) task suggest that hallucinations arise when maladaptive prior beliefs outweigh sensory evidence. Prior weighting is linked to hallucination severity, yet the nature of these priors remains unclear. Negative affect may influence the strength of maladaptive priors. We hypothesized that, under stress, participants will show increased CH rates and prior weighting, with this effect more pronounced in patients. Methods: This study employs a modified CH task using valenced linguistic stimuli and stress and non-stress affective manipulations. The sample for this pilot study included those at risk for psychosis and patients with first episode psychosis (N=12) and healthy controls (N=15). The objective of this study was first to validate this affective version of the CH task and then to demonstrate an effect of affect on CH rates and prior weighting. Results: Replicating past results, patients had higher CH rates (b = 0.061, p < 0.001) and prior weighting (b = 0.097, p < 0.001) for session 1 compared to controls (n=15) across conditions. Further, runs with stress manipulations had higher prior weighting across patients and controls compared to runs with non-stress manipulations (b = 0.054, p = 0.033). Conclusions: This study validates this affective version of the CH task and provides preliminary evidence of a relationship between affective state and prior weighting. Future work will be aimed at confirming and extending these findings, with the objective of developing biomarkers of early psychosis. Key words: Schizophrenia, Affect, Priors, Computational Psychiatry, Clinical High Risk Population, Psychotic Symptoms

q-bio.NC

pyhgf: A neural network library for predictive coding

Bayesian models of cognition have gained considerable traction in computational neuroscience and psychiatry. Their scopes are now expected to expand rapidly to artificial intelligence, providing general inference frameworks to support embodied, adaptable, and energy-efficient autonomous agents. A central theory in this domain is predictive coding, which posits that learning and behaviour are driven by hierarchical probabilistic inferences about the causes of sensory inputs. Biological realism constrains these networks to rely on simple local computations in the form of precision-weighted predictions and prediction errors. This can make this framework highly efficient, but its implementation comes with unique challenges on the software development side. Embedding such models in standard neural network libraries often becomes limiting, as these libraries' compilation and differentiation backends can force a conceptual separation between optimization algorithms and the systems being optimized. This critically departs from other biological principles such as self-monitoring, self-organisation, cellular growth and functional plasticity. In this paper, we introduce \texttt{pyhgf}: a Python package backed by JAX and Rust for creating, manipulating and sampling dynamic networks for predictive coding. We improve over other frameworks by enclosing the network components as transparent, modular and malleable variables in the message-passing steps. The resulting graphs can implement arbitrary computational complexities as beliefs propagation. But the transparency of core variables can also translate into inference processes that leverage self-organisation principles, and express structure learning, meta-learning or causal discovery as the consequence of network structural adaptation to surprising inputs. The code, tutorials and documentation are hosted at: https://github.com/ilabcode/pyhgf.

cs.NE