Table of Contents
Fetching ...

Modeling Latent Neural Dynamics with Gaussian Process Switching Linear Dynamical Systems

Amber Hu, David Zoltowski, Aditya Nair, David Anderson, Lea Duncker, Scott Linderman

TL;DR

This work addresses the challenge of learning interpretable yet expressive latent neural dynamics from high-dimensional time series. It introduces the gpSLDS, which integrates a novel Smoothly Switching Linear (SSL) kernel into a Gaussian Process–Stochastic Differential Equation framework to produce locally linear, smoothly interpolated dynamics with posterior uncertainty over the dynamics. The approach yields a fully probabilistic model that can recover fixed points and regime boundaries, and it demonstrates favorable performance on synthetic data as well as two real neural datasets, providing improved interpretability over rSLDS and standard GP-SDEs. The gpSLDS offers a principled framework for uncovering latent neural computations with uncertainty quantification and regime-specific structure, with practical impact for neuroscience data analysis and beyond.

Abstract

Understanding how the collective activity of neural populations relates to computation and ultimately behavior is a key goal in neuroscience. To this end, statistical methods which describe high-dimensional neural time series in terms of low-dimensional latent dynamics have played a fundamental role in characterizing neural systems. Yet, what constitutes a successful method involves two opposing criteria: (1) methods should be expressive enough to capture complex nonlinear dynamics, and (2) they should maintain a notion of interpretability often only warranted by simpler linear models. In this paper, we develop an approach that balances these two objectives: the Gaussian Process Switching Linear Dynamical System (gpSLDS). Our method builds on previous work modeling the latent state evolution via a stochastic differential equation whose nonlinear dynamics are described by a Gaussian process (GP-SDEs). We propose a novel kernel function which enforces smoothly interpolated locally linear dynamics, and therefore expresses flexible -- yet interpretable -- dynamics akin to those of recurrent switching linear dynamical systems (rSLDS). Our approach resolves key limitations of the rSLDS such as artifactual oscillations in dynamics near discrete state boundaries, while also providing posterior uncertainty estimates of the dynamics. To fit our models, we leverage a modified learning objective which improves the estimation accuracy of kernel hyperparameters compared to previous GP-SDE fitting approaches. We apply our method to synthetic data and data recorded in two neuroscience experiments and demonstrate favorable performance in comparison to the rSLDS.

Modeling Latent Neural Dynamics with Gaussian Process Switching Linear Dynamical Systems

TL;DR

This work addresses the challenge of learning interpretable yet expressive latent neural dynamics from high-dimensional time series. It introduces the gpSLDS, which integrates a novel Smoothly Switching Linear (SSL) kernel into a Gaussian Process–Stochastic Differential Equation framework to produce locally linear, smoothly interpolated dynamics with posterior uncertainty over the dynamics. The approach yields a fully probabilistic model that can recover fixed points and regime boundaries, and it demonstrates favorable performance on synthetic data as well as two real neural datasets, providing improved interpretability over rSLDS and standard GP-SDEs. The gpSLDS offers a principled framework for uncovering latent neural computations with uncertainty quantification and regime-specific structure, with practical impact for neuroscience data analysis and beyond.

Abstract

Understanding how the collective activity of neural populations relates to computation and ultimately behavior is a key goal in neuroscience. To this end, statistical methods which describe high-dimensional neural time series in terms of low-dimensional latent dynamics have played a fundamental role in characterizing neural systems. Yet, what constitutes a successful method involves two opposing criteria: (1) methods should be expressive enough to capture complex nonlinear dynamics, and (2) they should maintain a notion of interpretability often only warranted by simpler linear models. In this paper, we develop an approach that balances these two objectives: the Gaussian Process Switching Linear Dynamical System (gpSLDS). Our method builds on previous work modeling the latent state evolution via a stochastic differential equation whose nonlinear dynamics are described by a Gaussian process (GP-SDEs). We propose a novel kernel function which enforces smoothly interpolated locally linear dynamics, and therefore expresses flexible -- yet interpretable -- dynamics akin to those of recurrent switching linear dynamical systems (rSLDS). Our approach resolves key limitations of the rSLDS such as artifactual oscillations in dynamics near discrete state boundaries, while also providing posterior uncertainty estimates of the dynamics. To fit our models, we leverage a modified learning objective which improves the estimation accuracy of kernel hyperparameters compared to previous GP-SDE fitting approaches. We apply our method to synthetic data and data recorded in two neuroscience experiments and demonstrate favorable performance in comparison to the rSLDS.
Paper Structure (26 sections, 52 equations, 6 figures)

This paper contains 26 sections, 52 equations, 6 figures.

Figures (6)

  • Figure 1: SSL kernel and generative model. A. 1D function samples, plotted in different colors, from GPs with five kernels: two linear kernels with different hyperparameters, partition kernels for each of the two regimes, and the SSL kernel. B. (top) An example $\boldsymbol{\pi}(\boldsymbol{x})$ in 2D and (bottom) a sample of dynamics from a SSL kernel in 2D with $\boldsymbol{\pi}(\boldsymbol{x})$ as hyperparameters. The $x_1$- and $x_2$- directions of the arrows are given by independent 1D samples of the kernel. C. Schematic of the generative model. Simulated trajectories follow the sampled dynamics. Each trajectory is observed via Poisson process or Gaussian observations.
  • Figure 2: Synthetic data results. A. True dynamics and latent states used to generate the dataset. Dynamics are clockwise and counterclockwise linear systems separated by $x_1 = 0$. Two latent trajectories are shown on top of a kernel density estimate of the latent states visited by all 30 trials. B. Poisson process observations from an example trial. C. True vs. inferred latent states for the gpSLDS and rSLDS, with 95% posterior credible intervals. D. Inferred dynamics (pink/green) and two inferred latent trajectories (gray) corresponding to those in Panel A from a gpSLDS fit with 2 linear regimes. The model finds high-probability fixed points (purple) overlapping with true fixed points (stars). E. Analogous plot to D for the GP-SDE model with RBF kernel. Note that this model does not provide a partition of the dynamics. F. rSLDS inferred latents, dynamics, and fixed points (pink/green dots). G.(top) Sampled latents and corresponding dynamics from the gpSLDS, with $95\%$ posterior credible intervals. (bottom) Same, but for the rSLDS. The pink/green trace represents the most likely dynamics at the sampled latents, colored by discrete switching variable. H. MSE between true and inferred latents and dynamics for gpSLDS, GP-SDE with RBF kernel, and rSLDS while varying the number of trials in the dataset. Error bars are $\pm$2SE over 5 random initializations.
  • Figure 3: Results on hypothalamic data from nair2023approximate. In each of the panels A-C, flow field arrow widths are scaled by the magnitude of dynamics for clarity of visualization. A. rSLDS inferred latents and most likely dynamics. The presumed location of the line attractor from nair2023approximate is marked with a red box. B. gpSLDS inferred latents and most likely dynamics in latent space. Background is colored by posterior standard deviation of dynamics averaged across latent dimensions, which adjusts relative to the presence of data in the latent space. C. Posterior probability of slow points in gpSLDS, which validates line-attractor like dynamics, as marked by a red box. D. Comparison of in-sample forward simulation $R^2$ between gpSLDS, rSLDS, and GP-SDE with RBF kernel. To compute this, we choose initial conditions uniformly spaced 100 time bins apart in both trials, simulate latent states $k$ steps forward according to learned dynamics (with $k$ ranging from 100-1500), and evaluate the $R^2$ between predicted and true observations as in nassar2018tree. Error bars are $\pm$2SE over 5 different initializations.
  • Figure 4: Results on LIP spiking data from a decision-making task in stine2023neural. A. gpSLDS inferred latents colored by coherence, inferred dynamics with background colored by most likely linear regime, and the learned input-driven direction depicted by an orange arrow. B. Projection of latents onto the 1D input-driven axis from Panel A, colored by coherence (top) and choice (bottom). C. Inferred latents with 95% credible intervals and corresponding 100ms pulse input for an example trial. D. Posterior variance of dynamics produced by the gpSLDS.
  • Figure 5: Comparison between the standard vEM approach in duncker2019learning and our modified vEM approach. A. Estimation error between the true and learned decision boundaries, computed as described in Appendix \ref{['app:sec:learning_objective']}. For each vEM approach, we fit 5 gpSLDS models with different random initializations. The estimation errors are denoted in light blue/purple dots. The runs that we display in the next two panels are denoted by a solid blue/purple dot. B. The standard vEM approach fails to learn the true decision boundary of $x_1 = 0$. C. The modified vEM approach precisely learns this decision boundary.
  • ...and 1 more figures