Manuscript Offprint
arXiv:2610.10194Broadly Applicable Approximate MCMC for Switching Stochastic Differential Equations Using Uniformization and Time-Conditioned Factorized Neural Likelihood Estimation
Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.
Abstract
Switching stochastic differential equations (SSDEs) describe continuous-time dynamics whose parameters switch according to a latent regime process that follows a continuous-time Markov chain (CTMC). By allowing dynamics to change between regimes, SSDEs represent heterogeneous system behavior and have been applied across diverse fields. However, Bayesian inference for SSDEs remains difficult, and existing SSDE inference methods have limited applicability, with restrictions such as noise-free observations, univariate states, linear drift, or state-independent diffusion. In this study, we propose an approximate Markov chain Monte Carlo sampler for SSDEs using uniformization and factorized neural likelihood estimation (FNLE), a simulation-based inference method. Uniformization provides an exact representation of the CTMC but requires SDE transition densities over arbitrary time intervals. We approximate these densities by training a time-conditioned FNLE model. The resulting sampler is broadly applicable to SSDEs without requiring analytically tractable transition densities. In synthetic-data experiments, our method recovered regime paths and parameters for three SSDE models for which previous methods have limited applicability. We also applied our method to a real dataset and detected a regime transition.
1 INTRODUCTION
Stochastic differential equations (SDEs) provide a natural framework for modeling noisy continuous-time dynamics. A single SDE may be insufficient in many cases because dynamics in real-world systems often change. Switching stochastic differential equations (SSDEs) represent such dynamics by allowing the drift and diffusion functions to switch according to the regime at each time. SSDEs have been applied in many fields, such as ecology [36], biology [15], and economics [22]. Figure 1 illustrates an SSDE and its noisy observations.
Bayesian inference for SSDEs remains challenging. It requires joint estimation of latent states, regimes, and model parameters from noisy observations. Moreover, regime transitions can occur between observation times. Due to these challenges, existing SSDE inference methods have limited applicability and are typically restricted to settings with noise-free observations, univariate states, linear drift, or state-independent diffusion [13, 19, 20, 32].
Uniformization is a method to represent the continuous-time Markov chain (CTMC) by a discrete-time regime sequence on Poisson event times [30]. When regime-dependent emission likelihoods are available, this representation facilitates parameter inference in CTMC-based models and has been used in a range of applications [9, 12, 28]. For an SSDE, however, the required likelihood involves transition densities of the state process over each interval. These densities are generally unavailable for SDEs, limiting the direct use of uniformization-based regime updates in general SSDEs.
Simulation-based inference can learn otherwise intractable densities from simulations [5, 29]. Neural likelihood estimation learns conditional densities from simulated parameter–data pairs, while factorized neu-
Corresponding author: shion.hosoda@gmail.com.

Figure 1: Illustration of a simulated Lotka–Volterra SSDE. The upper panel shows the two components of the continuous state and their noisy observations. Background shading indicates the active regime, and the lower panel shows the regime path.
ral likelihood estimation (FNLE) exploits the Markov property to approximate trajectory likelihoods from learned local transition densities [11]. Standard FNLE is formulated for discrete-time Markovian sequences and is typically trained for a fixed transition interval, and it cannot be directly evaluated at the varying intervals introduced by uniformization.
In this study, we propose an approximate Markov chain Monte Carlo (MCMC) sampler for SSDEs using time-conditioned FNLE. As a foundation, we develop an exact uniformization-based sampler for SSDEs with tractable transition densities and conditional intermediate-state sampling. We then condition FNLE on elapsed time to approximate regime-specific transition densities over varying intervals and use sampling-importance-resampling (SIR) to approximate conditional intermediate-state sampling. This yields a broadly applicable sampler for SSDEs without requiring analytically tractable transition densities.
Our contributions are summarized as follows:
• We combine time-conditioned FNLE with uniformization to construct an approximate MCMC sampler applicable to a broad range of SSDEs.
• We show that the sampler successfully recovers regime paths and model parameters in synthetic experiments on three SSDE models spanning nonlinear drift, state-dependent diffusion, and multivariate latent states.
• We apply the sampler to a real dataset and infer a persistent regime change.
Our approach combines uniformization-based CTMC sampling [30] with FNLE, a simulation-based inference method for Markovian time series [11]. We use time-conditioned FNLE to approximate SDE transition densities over varying time intervals. Similarly, neural stochastic flows learn time-conditioned SDE transition distributions [17] but are formulated without conditioning on SDE parameters. In contrast, our transition-density approximation is conditioned on both time intervals and model parameters, allowing it to be incorporated into an approximate MCMC sampler that jointly infers latent states, regimes, and model parameters. Table 1 summarizes the differences between our method and existing SSDE inference approaches.
2 BACKGROUND
2.1 Switching Stochastic Differential Equations
A switching stochastic differential equation (SSDE) combines a continuous latent state with a regime that determines its drift and diffusion functions [27]. Let be a continuous latent state and let be a standard Brownian motion. The regime evolves as a CTMC, where is the state dimension and is the number of regimes. We con-
Table 1: Applicability of SSDE Inference Methods
| Method | Observation error | Nonlinear drift | State-dependent diffusion | Intractable transition density | Multivariate states |
|---|---|---|---|---|---|
| Blackwell et al. [3] | ✕ | ✓ | |||
| Hibbah et al. [13] | ✓ | ✓ | ✓ | ||
| Köhs et al. [19] | ✓ | ✕ | ✓ | ||
| Köhs et al. [20] | ✓ | ✕ | ✕ | ✕ | ✓ |
| Stumpf-Fétizon et al. [32] | ✓ | ✓ | ✓ | ||
| Proposed method | ✓ | ✓ | ✓ | ✓ | ✓ |
✓: Demonstrated applicability; △: Applicability not established; ×: Excluded by model assumptions.
sider an SSDE of the form
where and are the drift and diffusion functions, respectively. For each regime , and define the corresponding regime-specific SDE. The transition rate matrix of satisfies
On the observation interval , we write and for the state and regime paths. Their realizations are denoted by and .
2.2 Uniformization of Continuous-Time Markov Chains
Uniformization represents a CTMC as a discrete-time Markov chain observed at event times of a Poisson process [30]. For a fixed observation grid, augmenting the regime path with candidate times gives an equivalent discrete representation through the almost-sure one-to-one mapping
where combines the true jump times , at which the regime changes, and candidate times . For observations at fixed times , with , the combined grid is
Here, and are almost surely disjoint, and . The sequence is its realization, distinct from the full path . Under the right-continuous convention, is the regime on for ; and are the initial and terminal regimes.
As an illustrative model, consider conditionally independent latent states with densities and conditionally independent observations with densities , where is fixed and . Given and , observation factors cancel from the regime conditional. Writing and , we obtain
The transition matrix depends on , the uniformization rate , and whether is an event or observation-only time (Appendix A.1). This hidden Markov model (HMM) factorization permits forward-filtering backward-sampling (FFBS) [8].
Conditional on the current path and , candidate times are sampled as virtual-jump times from a Poisson process with rate , where is deterministic given (Appendix A.1). After FFBS, candidate times may become true jump times, and we update
2.3 Factorized Neural Likelihood Estimation for Transition Densities
Factorized neural likelihood estimation (FNLE) is a method for approximating intractable transition densities in Markov process models [11].
For a discrete-time Markov trajectory of length , the trajectory likelihood factorizes as
where denotes the parameters that determine the transition density.
FNLE learns by maximizing the conditional log-likelihood of simulated transitions, where denotes the density-estimator parameters. Conditional normalizing flows support both density evaluation and sampling [11, 29], enabling likelihood approximation and SIR proposals in our sampler.
3 PROBLEM SETTING
We define the model targeted by our proposed sampler. We assume that the drift and diffusion functions share common functional forms across regimes as follows:
where is the SDE parameter vector in regime k. Note that our method is not limited to this case and that functional forms can depend on regimes. We let collect the unconstrained SDE parameters, with separate entries for regime-specific parameters and a single entry for each shared parameter, and write
Here, selects the parameters used in regime k and applies the transformations required by their constraints.
At the discrete observation times in , observations are modeled as
Here, denotes the random observation at time , and denotes its realized value. We write and . Furthermore, is the vector of observation-noise variances. The initial state and regime have independent priors and that do not depend on the unknown parameters. Prior settings for unknown variables are provided in Appendix D.1.2. The target posterior distribution is written as
4 PROPOSED METHOD
We first construct an exact MCMC sampler for tractable SSDEs, then use time-conditioned FNLE to obtain an approximate sampler for intractable SSDEs. We call an SSDE tractable when exact transition-density evaluation and exact sampling from the corresponding bridge distribution are available for each regime-specific SDE. We refer to all other SSDEs as intractable in this sense. Here, a bridge distribution is the conditional distribution of the state path between two fixed times, given the endpoint states and the SDE parameters. We consider a single series; Appendix C.3 gives the extension to multiple series. On the combined grid in Eq. (4), write for and for . We write and for the restrictions of Y to the combined grid and the remaining times, respectively.
4.1 Exact MCMC for Tractable SSDEs
Uniformization augments the posterior in Eq. (12) with . For fixed , consider successive block Gibbs updates of , , and . The unused draws of can be trimmed by partially collapsed Gibbs sampling [7], leaving the following finite-dimensional updates. Consequently, only the grid values are explicitly sampled; the intervening paths are marginalized.
Candidate Times Given the current regime path and Q, we sample using the Poisson–Uniform construction in Section 2.2 and set and . The rate and uniformized transition matrix B are computed as in Appendix A.1.
Latent States at Newly Inserted Candidate Times Before updating all grid values, we sample each block of state values at candidate times from the bridge distribution
where is a consecutive block of , with fixed neighboring values and at adjacent points of .
For SSDEs, we redefine as the exact transition density for :
Because is the regime on , the transition to contributes .
Latent States on the Combined Time Grid We update using an MH kernel targeting
(15)
Regime Path Marginalizing gives
(16)
This HMM factorization permits FFBS; Appendix A.2.3 gives the derivation.
SDE Parameters The conditional density is
We update using an MH kernel targeting this conditional.
Observation Noise and Transition Rates We sample and the off-diagonal entries of Q from their conjugate full conditionals, with virtual jumps marginalized in the Q update; see Appendix C.2.
With exact sampling from the bridge distribution and conditional-invariant MH kernels, this sweep preserves the exact posterior marginal of the regime path, latent values at , and parameters [25]. Appendix A.2 gives the full derivation.
4.2 Time-Conditioned FNLE for SDE Transition Densities
To construct the approximate MCMC sampler, we approximate the SDE transition densities required by the exact updates. For a regime-specific SDE, the transition density is
Here, and are state values separated by elapsed time . We train an FNLE model with the elapsed time as a conditioning variable to obtain
A single FNLE model can be shared across regimes with common drift and diffusion forms by conditioning on ; otherwise, a separate model can be trained for each distinct pair of functional forms. The model and training settings are given in Appendix D.1.1.
4.3 Approximate Markov Chain Monte Carlo Sampler with FNLE
We obtain the approximate sampler by replacing the transition densities in Section 4.1 with FNLE densities and using SIR to sample state values at candidate times. For , define
Algorithm 1 Continuous-time SSDE sampler with time-conditioned FNLE
Require: Data Initial ; trained
1: Set
2: Initialize and on , consistent with
3: Compute (Eq. (28))
4: for iteration do
5: Sample (Section 2.2)
6: Set
7: Set (Eq. (4))
8: Re-evaluate on the new
9: SIR: sample
10: NUTS: sample (Eq. (15))
11: FFBS: sample (Eq. (16))
12: Set (Eq. (6))
13: NUTS: sample (Eq. (17))
14: Sample (Eq. (47))
15: Sample (Eq. (49))
16: Set (Eq. (50)); recompute
Replacing with in Eqs. (15), (16), and (17) defines the approximate conditionals on a fixed grid. The chain factorization still permits FFBS for . For and , we use the No-U-Turn Sampler (NUTS) [14], using gradients of the corresponding FNLE-based conditional log densities. The candidate-time, observation-noise, and transition-rate updates are unchanged.
For the state values at candidate times, SIR [31] approximates the bridge distribution in Eq. (13) with FNLE transition densities. Particles are sampled forward from the fixed left endpoint and weighted by the FNLE density at the fixed right endpoint (Appendix C.1). Thus, FNLE must support conditional sampling and differentiable density evaluation.
Algorithm Summary Algorithm 1 summarizes the proposed sampler with FNLE. Here, denotes the total number of MCMC sweeps. Appendix C.4 describes its per-sweep computational costs.
4.4 Approximation Properties
In our approximate MCMC sampler, FNLE approximates the transition densities, and the finite number of SIR particles introduces a separate error in sampling from the bridge distribution. Because FNLE densities do not necessarily satisfy the Chapman–Kolmogorov equation, inserting intermediate grid points can change the implied transition density. Consequently, successive sweeps apply the FNLE-based state, regime, and parameter updates on different grids and are not guaranteed to preserve a common approximate target. Exact or Chapman–Kolmogorov-consistent transition densities remove this inconsistency, but not the error due to the finite number of
SIR particles. On a fixed grid, an MH transition, such as NUTS with fixed tuning parameters, preserves its conditional target and introduces no additional target approximation [25].
We assess FNLE error through the displacement of conditional parameter modes. Consider one series with a realized combined time grid , and condition on fixed and . Let and be the exact and FNLE-based versions of the unnormalized conditional density in Eq. (17). Let contain the modes of both and . For , define the local log-density error as
(21)
Write and , and let . For a function , let , and let . We use oscillation because additive log-density errors independent of do not affect the modes. The following proposition bounds the displacement of conditional parameter modes caused by FNLE approximation.
Proposition 1 (Stability of FNLE-based conditional parameter modes). Assume that both and attain their maxima on for every and its associated fixed and . Choose any . Suppose that there exist and such that, uniformly over and its associated fixed and ,
(22)
For any , set . Let denote expectation over the uniformization event grid generated by a Poisson process with constant rate on , conditional on , with the observation grid fixed. Then
The first condition bounds parameter-dependent variation in the FNLE log-density error; the second is a quadratic separation condition requiring the normalized log posterior to decrease at least quadratically with distance from its mode set. Both conditions must hold uniformly over grids and fixed latent variables and are not guaranteed by FNLE training. This local sensitivity result does not guarantee the marginal posterior or the full sampler. At a fixed observation frequency , the bound remains uniformly bounded as increases, provided that , , and remain bounded. A proof is provided in Appendix B.
Exact MCMC
Approx. MCMC (exact FNLE)
Approx. MCMC (Euler-Maruyama FNLE)
Pointwise 95% credible interval (exact MCMC)
Pointwise 95% credible interval (approx. MCMC (exact FNLE))
Pointwise 95% credible interval (approx. MCMC (Euler-Maruyama FNLE))
True values
Observations
Posterior distributions of parameters

Latent state:
Posterior probability of regime 2
Figure 2: Comparison of inference results for the OU experiment using an exact MCMC sampler and two approximate MCMC samplers with FNLE trained on exact transitions and Euler–Maruyama simulations, respectively.
5 NUMERICAL EXPERIMENTS
MCMC settings and initialization are detailed in Appendix D.1.3. Computing infrastructure and software are described in Appendices D.5.1 and D.5.2, respectively.
5.1 Posterior Comparison on an Ornstein–Uhlenbeck Model
To assess the effect of FNLE approximation error, we compare posterior distributions obtained with two approximate MCMC samplers and an exact MCMC sampler (Section 4.1) for a tractable SSDE. We use an SSDE with K = 2 and an Ornstein–Uhlenbeck (OU) model [33] in each regime. In regime k, the model is
Here, is a one-dimensional standard Brownian motion. Each regime-specific OU SDE has an exact transition density and bridge distribution, making this SSDE tractable under the definition in Sec-
Table 2: Characteristics of the SSDE Models Used to Generate the Synthetic Datasets
| Model | Observation error | Nonlinear drift | State-dependent diffusion | Intractable transition density | Multivariate states |
|---|---|---|---|---|---|
| Ornstein-Uhlenbeck | ✓ | ✕ | ✕ | ✕ | ✕ |
| Lotka-Volterra | ✓ | ✓ | ✓ | ✓ | ✓ |
| Gene-expression CLE | ✓ | ✕ | ✓ | ✓ | ✓ |
| Susceptible-infected-recovered epidemic model | ✓ | ✓ | ✓ | ✓ | ✓ |
✓: Present; ×: Absent.

— Latent truth
Pointwise 95% credible interval
Posterior mean
Observations

Figure 3: Inference results for synthetic data from three SSDEs with regime-specific Lotka–Volterra, gene-expression chemical Langevin, and susceptible-infected-recovered epidemic models (left to right).
tion 4. Figure 2 compares posterior parameter distributions from the three samplers. The sampler using FNLE trained on exact transitions produces posterior marginals close to those from the exact sampler. The marginals remain similar when FNLE is trained on Euler–Maruyama simulations instead, as in the subsequent experiments on intractable SSDEs. All three samplers recovered the SDE parameters and regime path, with values close to one (Appendix Table 10). The experimental settings are given in Appendix D.2.1.
5.2 Synthetic-Data Experiments
We evaluate regime-path recovery and estimation of using synthetic data from three SSDE models with and known regimes and parameters. The remaining three rows of Table 2 summarize these intractable SSDEs; the first row describes the tractable OU benchmark in Section 5.1.
All three models include observation error, state-dependent diffusion, and multivariate latent states. The previous methods in Table 1 have not demonstrated applications combining these features.
and denote independent Brownian motions. Complete settings of these three experiments are given in Appendices D.2.2, D.2.3, and D.2.4, respectively.
Lotka–Volterra Equation We write and for predator and prey abundance, respectively. The drift follows the classical Lotka–Volterra (LV) predator–prey model [26, 35], and independent multiplicative noise is introduced as in Li and Mao [23]. In regime k, the model is
Chemical Langevin Equation We write for the mRNA copy number and for the fluorescence intensity proportional to the protein copy number, using continuous approximations to the copy numbers. We use a chemical Langevin equation (CLE) [10], whose dynamics in regime k are
For inference, we reparameterize the CLE using and instead of and to improve MCMC mixing. The coefficient converts protein copy number to fluorescence intensity.
Susceptible–Infected–Recovered Epidemic Model We write and for the susceptible and recovered populations, respectively. The drift follows the classical susceptible–infected–recovered epidemic model [16], and the diffusion terms follow the chemical Langevin approximation [10]. The infected population is determined by , where is the fixed total population. In regime , the model is
Posterior means were close to the true parameters with narrow 95% credible intervals in all three experiments (Figure 3). The posterior regime probabilities also recovered the true switching pattern. The parameter in the CLE experiment and in the susceptible-infected-recovered experiment showed poor mixing (Appendix Tables 12 and 13); diagnostics for the LV experiment are in Appendix Table 11.
5.3 Real-Data Application
We applied the proposed method to 71 paired abundance observations of Didinium and Paramecium from Veilleux [34], using the LV SSDE in Eq. (25) with

Figure 4: Real-data inference results for the Didinium–Paramecium time series using a Lotka–Volterra SSDE.
K = 2. Data preprocessing and inference settings are given in Appendix D.3.
As shown in Figure 4, the posterior probability of regime 2 increased around t = 7 and remained close to one thereafter. Notably, the initial regime identified in an unsupervised manner closely corresponds to the transient period that was manually excluded prior to fitting a LV model in a previous analysis of these data [24]. Appendix Figure 5 shows similar chain-specific marginal posterior distributions and overlapping traces across the four chains. The diagnostics in Appendix Table 14 also suggest convergence.
6 CONCLUSION
We proposed a broadly applicable approximate MCMC sampler combining time-conditioned FNLE and uniformization for joint inference of SSDE latent states, regimes, and parameters. Starting from an exact uniformization-based MCMC sampler for tractable SSDEs, we used FNLE to approximate transition densities and SIR to sample approximately from bridge distributions, extending the approach to intractable SSDEs. In the OU benchmark, approximate samplers using FNLE trained on exact or Euler–Maruyama transitions produced posterior parameter marginals similar to those from exact MCMC. The approximate sampler also recovered parameters and regime paths for the three SSDE models, to which existing methods have limited applicability. In the real-data analysis of the Didinium–Paramecium time series, the method identified a persistent regime transition from the initial transient dynamics to the subsequent predator–prey dynamics.
AI use statement
In this work, we used generative AI tools to help develop theoretical models or conceptual frameworks, formulate mathematical claims, provide critical ingredients for proving mathematical claims, assist in the writing of proofs, design or provide feedback on research methodology or experiments, implement methods, and assist with translation. We have not used generative AI tools to generate synthetic datasets, propose or refine hypotheses, clean and reformat datasets, support qualitative and thematic data analysis, or interpret results. Additionally, we used generative AI tools to create or modify scientific figures or images, suggest experimental parameters, create or edit software code, draft parts of a research paper, summarize or analyze existing literature, brainstorm, source or search for information, edit a research paper to improve readability, identify relevant literature, and propose a title or keywords. We have reviewed all AI-assisted work. We manually reviewed all LLM-generated code, draft text, and proofs. All changes, whether AI-assisted or manual, were tracked using git, and we inspected the corresponding diffs to carefully review modifications made with the assistance of LLMs. LLM-assisted proofs were checked by the authors for correctness. All references were added to the BibTeX file manually after verifying their bibliographic information against the original sources and reading the cited works to confirm their content and relevance. We take responsibility for the final content of this work, including text, claims, or artifacts produced with the aid of generative AI.
Code Availability
The code for the numerical experiments is available at https://github.com/shion-h/fnle-ssde.
References
[1] Eli Bingham, Jonathan P. Chen, Martin Jankowiak, Fritz Obermeyer, Neeraj Pradhan, Theofanis Karaletsos, Rohit Singh, Paul A. Szerlip, Paul Horsfall, and Noah D. Goodman. Pyro: Deep universal probabilistic programming. J. Mach. Learn. Res., 20:28:1–28:6, 2019. URL http://jmlr.org/papers/v20/18-403.html.
[2] P. G. Blackwell. Bayesian inference for Markov processes with diffusion and discrete components. Biometrika, 90(3):613–627, 09 2003. ISSN 0006-3444. doi: 10.1093/biomet/90.3.613. URL https://doi.org/10.1093/biomet/90.3.613.
[3] Paul G. Blackwell, Mu Niu, Mark S. Lambert, and Scott D. LaPoint. Exact Bayesian inference for animal movement in continuous time. Methods in Ecology and Evolution, 7(2):184–195, 2016. doi:
https://doi.org/10.1111/2041-210X.12460. URL https://besjournals.onlinelibrary.wiley.com/doi/abs/10.1111/2041-210X.12460.
[4] Jan Boelts, Michael Deistler, Manuel Gloeckler, Álvaro Tejero-Cantero, Jan-Matthis Lueckmann, Guy Moss, Peter Steinbach, Thomas Moreau, Fabio Muratore, Julia Linhart, Conor Durkan, Julius Vetter, Benjamin Kurt Miller, Maternus Herold, Abolfazl Ziaemehr, Matthijs Pals, Theo Gruner, Sebastian Bischoff, Nastya Krouglova, Richard Gao, Janne K. Lappalainen, Bálint Mucsányi, Felix Pei, Auguste Schulz, Zinovia Stefanidi, Pedro Rodrigues, Cornelius Schröder, Faried Abu Zaid, Jonas Beck, Jaivardhan Kapoor, David S. Greenberg, Pedro J. Gonçalves, and Jakob H. Macke. sbi reloaded: a toolkit for simulation-based inference workflows. Journal of Open Source Software, 10(108):7754, 2025. doi:10.21105/joss.07754. URL https://doi.org/10.21105/joss.07754.
[5] Kyle Cranmer, Johann Brehmer, and Gilles Louppe. The frontier of simulation-based inference. Proceedings of the National Academy of Sciences, 117(48):30055–30062, 2020. doi: 10.1073/pnas.1912789117. URL https://www.pnas.org/doi/abs/10.1073/pnas.1912789117.
[6] Conor Durkan, Artur Bekasov, Iain Murray, and George Papamakarios. Neural spline flows. In Proceedings of the 33rd International Conference on Neural Information Processing Systems, Red Hook, NY, USA, 2019. Curran Associates Inc.
[7] David A. Van Dyk and Taeyoung Park. Partially collapsed Gibbs samplers: Theory and methods. Journal of the American Statistical Association, 103(482):790–796, 2008. ISSN 01621459. URL http://www.jstor.org/stable/27640101.
[8] S. Frühwirth-Schnatter. Finite Mixture and Markov Switching Models. Springer Series in Statistics. Springer New York, 2006. ISBN 9780387357683. URL https://books.google.ne/books?id=f8KiI7eRjYoC.
[9] Anastasis Georgoulas, Jane Hillston, and Guid Sanguinetti. ProPPA: Probabilistic programming for stochastic dynamical systems. ACM Trans. Model. Comput. Simul., 28(1), January 2018. ISSN 1049-3301. doi: 10.1145/3154392. URL https://doi.org/10.1145/3154392.
[10] Daniel T. Gillespie. The chemical Langevin equation. The Journal of Chemical Physics, 113(1):297–306, 07 2000. ISSN 0021-9606. doi: 10.1063/1.481811. URL https://doi.org/10.1063/1.481811.
[11] Manuel Gloeckler, Shoji Toyota, Kenji Fukumizu, and Jakob H. Macke. Compositional simulation-based inference for time series. In The Thirteenth International Conference on Learning Representations, 2025. URL https://openreview.net/forum?id=uC1UUJk05H.
[12] Flávio B Gonçalves, Lívia M Dutra, and Roger WC Silva. Exact and computationally efficient Bayesian inference for generalized Markov modulated Poisson processes. Statistics and Computing, 32(1):14, 2022.
[13] El Houcine Hibbah, Hamid El Maroufy, Christiane Fuchs, and Taib Ziad. An MCMC computational approach for a continuous time state-dependent regime switching diffusion process. Journal of Applied Statistics, 47(8):1354–1374, 2020. doi: 10.1080/02664763.2019.1677573. URL https://doi.org/10.1080/02664763.2019.1677573. PMID: 35706700.
[14] Matthew D. Hoffman and Andrew Gelman. The No-U-Turn Sampler: Adaptively Setting Path Lengths in Hamiltonian Monte Carlo. Journal of Machine Learning Research, 15(47):1593–1623, 2014. ISSN 1533-7928.
[15] Shion Hosoda, Tsukasa Fukunaga, and Michiaki Hamada. Umibato: Estimation of time-varying microbial interaction using continuous-time regression hidden Markov model. Bioinformatics, 37(Supplement_1):i16–i24, July 2021. ISSN 1367-4803. doi: 10.1093/bioinformatics/btab287.
[16] William Ogilvy Kermack and A. G. McKendrick. A contribution to the mathematical theory of epidemics. Proceedings of the Royal Society of London. Series A, Containing Papers of a Mathematical and Physical Character, 115(772):700–721, 08 1927. ISSN 0950-1207. doi: 10.1098/rspa.1927.0118. URL https://doi.org/10.1098/rspa.1927.0118.
[17] Naoki Kiyohara, Edward Johns, and Yingzhen Li. Neural stochastic flows: Solver-free modelling and inference for SDE solutions. In D. Belgrave, C. Zhang, H. Lin, R. Pascanu, P. Koniusz, M. Ghassemi, and N. Chen, editors, Advances in Neural Information Processing Systems, volume 38, pages 16917–16962. Curran Associates, Inc., 2025. doi: 10.52202/085713-0571. URL https://proceedings.neurips.cc/paper_files/paper/2025/file/18abbeef8cfe9203fdf9053c9c4fe191-Paper-Conference.pdf.
[18] P.E. Kloeden and E. Platen. Numerical Solution of Stochastic Differential Equations. Stochastic Modelling and Applied Probability. Springer Berlin Heidelberg, 2013. ISBN 9783662126165. URL https://books.google.co.jp/books?id=r9r6CAAAQBAJ.
[19] Lukas Köhs, Bastian Alt, and Heinz Koepp. Variational Inference for Continuous-Time Switching Dynamical Systems. In Advances in Neural Information Processing Systems, volume 34, pages 20545–20557. Curran Associates, Inc., 2021.
[20] Lukas Köhs, Bastian Alt, and Heinz Koepp. Markov Chain Monte Carlo for Continuous-Time Switching Dynamical Systems. In Proceedings of the 39th International Conference on Machine Learning, pages 11430–11454. PMLR, June 2022.
[21] Ravin Kumar, Colin Carroll, Ari Hartikainen, and Osvaldo Martin. Arviz a unified library for exploratory analysis of bayesian models in python. Journal of Open Source Software, 4(33):1143, 2019. doi: 10.21105/joss.01143. URL https://doi.org/10.21105/joss.01143.
[22] Haitao Li, Tao Li, and Cindy Yu. No-arbitrage Taylor rules with switching regimes. Management Science, 59(10):2278–2294, 2013. doi: 10.1287/mnsc.1120.1702. URL https://doi.org/10.1287/mnsc.1120.1702.
[23] Xiaoyue Li and Xuerong Mao. Population dynamical behavior of non-autonomous Lotka-Volterra competitive system with random perturbation. Discrete and Continuous Dynamical Systems, 24(2):523–545, 2009.
[24] Chen Liao, Joao B Xavier, and Zhenduo Zhu. Enhanced inference of ecological networks by parameterizing ensembles of population dynamics models constrained with prior knowledge. BMC ecology, 20(1):3, 2020.
[25] Jun S. Liu. Monte Carlo Strategies in Scientific Computing. Springer, 2001.
[26] Alfred J. Lotka. Analytical note on certain rhythmic relations in organic systems. Proceedings of the National Academy of Sciences, 6(7):410–415, 1920. doi: 10.1073/pnas.6.7.410. URL https://www.pnas.org/doi/abs/10.1073/pnas.6.7.410.
[27] X. Mao and C. Yuan. Stochastic Differential Equations with Markovian Switching. G-Reference, Information and Interdisciplinary Subjects Series. Imperial College Press, 2006. ISBN 9781860947018. URL https://books.google.co.jp/books?id=mEMMAFGfr1sC.
[28] Jiangwei Pan, Vinayak Rao, Pankaj Agarwal, and Alan Gelfand. Markov-modulated marked Poisson processes for check-in data. In Maria Florina Balcan and Kilian Q. Weinberger, editors, Proceedings of The 33rd International Conference on Machine Learning, volume 48 of Proceedings of Machine Learning Research, pages 2244–2253, New York, New York, USA, 20–22 Jun 2016.
PMLR. URL https://proceedings.mlr.press/v48/pana16.html.
[29] George Papamakarios, David Sterratt, and Iain Murray. Sequential Neural Likelihood: Fast Likelihood-free Inference with Autoregressive Flows. In Proceedings of the Twenty-Second International Conference on Artificial Intelligence and Statistics, pages 837–848. PMLR, April 2019.
[30] Vinayak Rao and Yee Whye Teh. Fast MCMC Sampling for Markov Jump Processes and Extensions. Journal of Machine Learning Research, 14(103):3295–3320, 2013. ISSN 1533-7928.
[31] Donald B. Rubin. The calculation of posterior distributions by data augmentation: Comment: A noniterative sampling/importance resampling alternative to the data augmentation algorithm for creating a few imputations when fractions of missing information are modest: The SIR algorithm. Journal of the American Statistical Association, 82(398):543–546, 1987. ISSN 01621459, 1537274X. URL http://www.jstor.org/stable/2289460.
[32] Timothée Stumpf-Fétizon, Krzysztof Latuszyński, Jan Palczewski, and Gareth Roberts. Exact Bayesian inference for Markov switching diffusions. Journal of the Royal Statistical Society Series B: Statistical Methodology, page qkag115, July 2026. ISSN 1369-7412. doi:10.1093/jrsssb/qkag115.
[33] G. E. Uhlenbeck and L. S. Ornstein. On the theory of the brownian motion. Phys. Rev., 36:823–841, Sep 1930. doi: 10.1103/PhysRev.36.823. URL https://link.aps.org/doi/10.1103/PhysRev.36.823.
[34] B. G. Veilleux. An analysis of the predatory interaction between Paramecium and Didinium. Journal of Animal Ecology, 48(3):787–803, 1979. ISSN 00218790, 13652656. URL http://www.jstor.org/stable/4195.
[35] Vito Volterra. Fluctuations in the abundance of a species considered mathematically. Nature, 119: 12–13, 1927.
[36] Jun Yan, Yung-wei Chen, Kirstin Lawrence-Apfel, Isaac M. Ortega, Vladimir Pozdnyakov, Scott Williams, and Thomas Meyer. A moving-resting process with an embedded Brownian motion for animal movements. Population Ecology, 56(2):401–415, 2014. doi: https://doi.org/10.1007/s10144-013-0428-8. URL https://esj-journals.onlinelibrary.wiley.com/doi/abs/10.1007/s10144-013-0428-8.
Broadly Applicable Approximate MCMC for Switching Stochastic Differential Equations Using Uniformization and Time-Conditioned Factorized Neural Likelihood Estimation: Supplementary Materials
A EXACT SAMPLING CONSTRUCTION
We derive an exact version of Algorithm 1 from the proper full-path posterior in Eq. (12), assuming exact SDE transition densities and sampling from bridge distributions are available. For any time set , define and , with realizations denoted by lowercase symbols, and let . Each sweep first samples conditional on the current regime, retained state values, and parameters. With the resulting and fixed, it updates the blocks , , and , followed by . The candidate-time augmentation is then marginalized before updating . The factorizations below permit trimming unused path draws by partially collapsed Gibbs sampling [7].
A.1 Uniformization Matrices and Candidate Times
For a transition rate matrix , choose a deterministic rate . The uniformized chain has transition matrix [30]
where is the identity matrix. On , event times permit regime transitions, whereas observation-only times preserve the regime:
Event times almost surely do not coincide with the fixed observation times. See Rao and Teh [30] for the uniformization construction and its MCMC application.
For candidate generation, let , be the intervals between consecutive times in , with regime in each interval's interior. Conditional on the current path and , sample independently across intervals
followed by
where Poisson() has mean , and Uniform is uniform on . The sampled times form .
A.2 Block Gibbs Construction
A.2.1 Candidate Grids and Path Augmentation
Conditional on , is fixed, and the update factors by conditional independence:
The first factor is the conditional Poisson process in Eqs. (30) and (31) [30].
Use the local indices from Eq. (13), with endpoints and consecutive in and regime between them. By the Markov property and the Chapman–Kolmogorov equation, its candidate-time marginal is
(33)
Sampling the intervening paths from their bridge distributions conditional on yields .
A.2.2 Latent-State Update
The Y block factors as
(34)
Since is the regime on , the Markov property gives
(35)
Multiplying by gives Eq. (15).
A.2.3 Regime Conditional Distribution
The block factors as
(36)
Uniformization [30] and identity transitions at observation-only times give
(37)
Here, is the Poisson-process density. Bayes' rule with Eqs. (37) and (35) expresses the first factor in Eq. (36) as Eq. (16).
A.2.4 Parameter Updates
The block factors as
(38)
Using Eq. (35) and the independent prior for gives Eq. (17) for the first factor. The update in Eq. (47) depends on Y only through .
Marginalizing recovers Eq. (12), under which follows Eq. (49). After this collapsed update, new candidate times must be generated using the updated before any further grid-dependent update [7].
A.2.5 Trimming and Invariance Across Iterations
Within a sweep, each draw of is unused by the subsequent marginal update; the and Q updates also require no such values.
Every updated true-jump time lies in , implying that the updated is a subset of the current . Equation (32) resamples the path outside this retained set before any values at new candidate times are used. Thus, the final intervening-path draw of the previous sweep is also unused.
Trimming these draws preserves the retained-variable transition kernel [7]. The block updates and augmentation preserve the full-path posterior marginal; hence, at sweep boundaries, the invariant distribution is the marginal of Eq. (12) on
In particular, its marginal is the desired posterior marginal.
For fixed , the retained conditionals share the same marginalized posterior. The and draws may therefore be replaced by Markov transitions preserving their respective conditionals, including NUTS with fixed tuning [14, 25].
B PROOF OF PROPOSITION 1
Proof. Fix a realized grid G and its associated and . Because the exact and FNLE-based conditional densities differ only in their transition-density factors, they can be written with a common multiplicative convention as
Any omitted factors are independent of and therefore do not affect either conditional mode. The common prior factor cancels from the difference between the normalized log densities, and we have
For arbitrary functions on K,
Applying this inequality to the local errors and using the first condition in Eq. (22) yields
(40)
The maximizing property of gives
Substituting and rearranging gives
Combining the second condition in Eq. (22) with Eq. (40) therefore gives
Consequently, every realized grid satisfies the pointwise bound
It remains to average Eq. (41) over the joint uniformization construction. Let be the number of uniformization events. Conditional on , the event process is a Poisson process with rate , and hence
The Poisson event times are almost surely distinct from one another and from the N fixed observation times, and almost surely and
The pointwise bound in Eq. (41) is uniform in the associated fixed y and z, and only the distribution of L is needed below. Taking conditional expectations in Eq. (41) and applying Jensen's inequality to the concave square-root function gives
where the final equality follows from Eq. (42). This is Eq. (23) and completes the proof.
C ALGORITHMIC DETAILS AND EXTENSIONS
C.1 Sampling State Values at Candidate Times with SIR
Before applying the NUTS update to , we use sampling-importance-resampling (SIR) to assign latent values . Using local indices on the combined time grid containing the newly sampled , consider a consecutive block of current state values at candidate times with fixed neighboring values and at adjacent points of . For particle , we simulate
with . Because the proposal is the forward FNLE transition-density approximation from the left endpoint, the SIR weight is
We then draw and set . This construction is applied to every interval between consecutive points of that contains at least one current candidate time.
C.2 Conjugate Parameter Updates
Let denote the -th element of . Assume independent priors and for , with the Gamma distribution parameterized by shape and rate. Here, denotes the inverse-Gamma distribution with shape and scale , whose density is proportional to for . Let
The conjugate observation-noise update used in Algorithm 1 is
Let be the number of true jumps from k to h, and let
be the total holding time in regime k. After marginalizing the virtual jumps, the conjugate update is
The diagonal entries are set to
C.3 Extension to Multiple Time Series
Suppose that time series are conditionally independent given the shared parameters . Series has its own observations, latent state process, regime path, and combined time grid, denoted by , and , respectively. Let be its number of observations, its number of combined grid points, and its observation interval. We use , and for its latent states and regimes at the grid points, and its interval lengths, respectively.
The initialization and the candidate-grid, latent-state, and regime updates in Algorithm 1 are performed separately for each series. The shared parameters are then updated using the contributions from all series, with each prior included only once. The FNLE-based conditional density corresponding to Eq. (17) becomes
For the observation-noise update in Eq. (47), replace N by and by , where
is the residual sum of squares for component in series . For Eq. (49), replace and by and , where counts the true jumps from to in series , and
is its holding time in regime k.
C.4 Computational Complexity
For one sweep with combined grid points, regimes, and SIR particles, constructing the emission factors requires FNLE density evaluations, followed by arithmetic operations for FFBS [30]. SIR requires conditional FNLE samples and density evaluations across all candidate blocks. The NUTS cost depends on its trajectory-dependent number of gradient evaluations, each involving local FNLE terms, together with observation and prior terms [14]. These costs exclude offline FNLE training.
D EXPERIMENTAL SETTINGS
This appendix records the settings for the synthetic-data experiments (OU comparison, LV, gene-expression CLE, and susceptible-infected-recovered) and the real-data LV analysis.
D.1 Settings for the Main Experiments
The synthetic-data LV, gene-expression CLE, and susceptible-infected-recovered experiments, along with the real-data LV analysis, use two regimes and observe every state component with Gaussian errors as in Eq. (10).
D.1.1 FNLE Training
The time-conditioned FNLE training dataset is
where is the number of simulated transitions and r indexes training examples rather than positions in a trajectory. The density estimator is trained by maximizing the conditional log-likelihood
Omitting elapsed-time conditioning gives the standard FNLE training objective.
A separate time-conditioned FNLE model was trained for each experiment. We used preliminary MCMC draws to check whether the FNLE parameter training ranges in Sections D.2.5 and D.3 covered the parameter regions relevant to inference. Where needed, we expanded the ranges, retrained FNLE, and reran MCMC. These adjustments refine the numerical likelihood approximation without changing the SSDE model or prior.
A natural cubic spline through that experiment’s observations was evaluated on an Euler–Maruyama grid [18] with step size to obtain a reference path. Negative spline values were truncated at zero. For every training example, each component of was sampled uniformly between the logarithms of the corresponding physical-scale bounds reported below, and was then obtained by exponentiation. For each training example, one location was selected from the reference path. Isotropic Gaussian noise with standard deviation 0.32 was added to this state. If the perturbed state left , the noise was redrawn until the state lay inside this domain.
The maximum elapsed time required for density evaluation is bounded by the largest observation interval, which determines the required training range. The number of numerical transitions, n, was sampled uniformly from , and the elapsed time was . The simulator was advanced by n Euler–Maruyama steps, and FNLE was trained on the scaled increment
conditional on . When the learned density of is evaluated as a transition density for , the change of variables gives
(57)
Table 3: Experiment-Specific FNLE Training Settings.
| Experiment | ||
|---|---|---|
| Synthetic-data OU (approx. MCMC with Euler–Maruyama FNLE) | 100 | 1.00 |
| Synthetic-data LV | 100 | 1.00 |
| Synthetic-data gene-expression CLE | 25 | 0.25 |
| Synthetic-data susceptible-infected-recovered | 20 | 0.20 |
| Real-data LV | 98 | 0.98 |
Table 4: Priors for the Observation Variances
| Experiment | Component | Prior |
|---|---|---|
| Synthetic-data OU | scalar state | |
| Synthetic-data LV | predator | |
| Synthetic-data LV | prey | |
| Synthetic-data gene-expression CLE | mRNA | |
| Synthetic-data gene-expression CLE | protein fluorescence | |
| Synthetic-data susceptible-infected-recovered | susceptible | |
| Synthetic-data susceptible-infected-recovered | recovered | |
| Real-data LV | Didinium | |
| Real-data LV | Paramecium |
Thus, Eq. (56) is a target reparameterization and does not change the underlying transition model. For the OU experiment, the two FNLE training sets shared identical conditioning inputs () and differed only in how was generated. For approximate MCMC with FNLE (exact-transition training), it was sampled from the exact transition density in Appendix D.2.1; for approximate MCMC with FNLE (Euler–Maruyama training), it was generated by Euler–Maruyama.
Every FNLE model was a neural spline flow [6] with 50 hidden features, five transforms, and ten spline bins. Each synthetic-data training set contained 100,000 independently sampled parameter settings, and the real-data training set contained 800,000, with one simulated transition per setting. Training used a batch size of 256, a learning rate of , at most 100 epochs, and early stopping after 20 epochs without validation-loss improvement. The density estimator and batch size were selected through preliminary experiments, and maximum epoch counts were set according to the available computational budget. All other FNLE training hyperparameters used the sbi defaults, including reserving 10% of the simulated transitions for validation. The experiment-specific transition-length settings and final epoch counts are given in Table 3.
D.1.2 Prior Settings
SDE parameter priors and parameter-sharing structures are given in Sections D.2.5 and D.3. Each prior is evaluated once per unique parameter. Here, denotes a distribution whose natural logarithm is Gaussian with mean and standard deviation . The initial regime probabilities were , and the initial state had an improper uniform prior, on .
The observation-variance priors are , with the experiment-specific settings listed in Table 4.
In all experiments, the off-diagonal CTMC rates independently followed Gamma(2, 20) in the shape-rate parameterization.
D.1.3 MCMC Settings and Initialization
The deterministic uniformization rate used and a numerical safeguard in
Table 5: Fixed NUTS Step Sizes by Experiment and Sampler
| Experiment | State path | Parameters |
|---|---|---|
| Synthetic-data OU (exact MCMC) | ||
| Synthetic-data OU (approx. MCMC with exact FNLE) | ||
| Synthetic-data OU (approx. MCMC with Euler-Maruyama FNLE) | ||
| Synthetic-data LV | ||
| Synthetic-data gene-expression CLE | ||
| Synthetic-data susceptible-infected-recovered | ||
| Real-data LV |
Table 6: MCMC Chain Counts and Lengths Used for Posterior Summaries. Sweep, burn-in, and retained-draw counts are per chain.
| Experiment | Chains | Sweeps | Burn-in | Retained |
|---|---|---|---|---|
| Synthetic-data OU (exact MCMC) | 4 | 10,000 | 5,000 | 5,000 |
| Synthetic-data OU (approx. MCMC with exact FNLE) | 4 | 10,000 | 5,000 | 5,000 |
| Synthetic-data OU (approx. MCMC with Euler-Maruyama FNLE) | 4 | 10,000 | 5,000 | 5,000 |
| Synthetic-data LV | 4 | 10,000 | 5,000 | 5,000 |
| Synthetic-data gene-expression CLE | 4 | 10,000 | 5,000 | 5,000 |
| Synthetic-data susceptible-infected-recovered | 4 | 10,000 | 5,000 | 5,000 |
| Real-data LV | 4 | 10,000 | 5,000 | 5,000 |
After computing , negative entries caused by numerical error were clipped to zero and each row was renormalized. Newly inserted candidate-time states were sampled by sampling-importance-resampling with 100 particles. The continuous path and nonredundant SDE parameters were updated conditionally using Pyro NUTS. Before the production runs, we used Pyro's step-size adaptation in preliminary runs and fixed the resulting step sizes. Table 5 lists the step sizes for the state-path and parameter updates by experiment and sampler. The production chains used one NUTS draw per sweep, with no warm-up or further step-size adaptation. In all experiments, the maximum tree depth was 5 for the state-path update and 3 for the parameter update; these values were selected in preliminary experiments based on the observed divergence rates and sample displacements. The regime path was updated by log-space forward filtering and backward sampling.
At initialization, SDE parameters were sampled from their experiment-specific priors conditional on lying inside the corresponding FNLE ranges. Shared components were sampled once and copied across regimes. Every off-diagonal CTMC rate and observation variance was sampled from its prior. The initial regime path was simulated from an auxiliary symmetric CTMC with for the synthetic-data OU and LV experiments, 0.4 for the synthetic-data gene-expression CLE experiment, and 0.5 for the synthetic-data susceptible-infected-recovered and real-data LV experiments. This generator was used only to initialize the regime path, independently of the initial drawn from its prior. The initial continuous path was obtained by linear interpolation of the observations. FNLE training and the synthetic-data chains used random seed zero; the four real-data chains used seeds zero through three. Chain lengths are summarized in Table 6. For trajectory summaries, each sampled path was linearly interpolated between its grid points onto a common plotting grid before computing pointwise posterior credible intervals.
D.2 Synthetic-Data Experiments
D.2.1 Ornstein–Uhlenbeck Experiment
The OU experiment used Eq. (24). On an interval of length with regime fixed, define and . The exact transition and one-time bridge distributions are
For multiple interior times, the joint bridge distribution follows from Eq. (33) and is multivariate Gaussian. Exact MCMC uses the transition density directly, while approximate MCMC with FNLE (exact-transition training) uses it only to generate FNLE training transitions and uses the learned density at inference. The exact bridge distribution is used only by exact MCMC; both approximate samplers use the FNLE-based SIR bridge update. Conditional on this path, the state was simulated by Euler–Maruyama with step size and independent Brownian increments.
The initial state was . The observation standard deviations were . The observation period was , with 101 observations at spacing 1.0.
D.2.2 Switching Lotka–Volterra Experiment
The LV experiment used Eq. (25). The regime path was simulated from a two-state CTMC with initial probabilities , exact holding times, and exact jump destinations. Conditional on this path, the state was simulated by Euler–Maruyama with step size and independent Brownian increments. After each step, the state was restricted to componentwise.
The initial state was , and the data-generating CTMC rates were . The observation standard deviations were . The observation period was , with 101 observations at spacing 1.0.
D.2.3 Switching Gene-Expression CLE Experiment
The gene-expression CLE experiment used Eq. (26). The regime path was simulated from a two-state CTMC with initial probabilities , exact holding times, and exact jump destinations. Conditional on this path, the state was simulated by Euler–Maruyama with step size and independent Brownian increments. After each step, the state was restricted to componentwise. To see the change of scale, let be the continuous approximation to the protein copy number, with translation rate per mRNA molecule and degradation rate . Its chemical Langevin equation is
The transformation , with , gives Eq. (26). Thus, is the fluorescence-scaled production coefficient, and converts protein copy number to fluorescence intensity.
The initial state was , and the data-generating CTMC rates were . The observation standard deviations were and . The observation period was , with 201 observations at spacing 0.25.
D.2.4 Switching Susceptible–Infected–Recovered Epidemic Experiment
The susceptible-infected-recovered experiment used Eq. (27), with fixed total population . The regime path had a single prescribed switch at the midpoint of the observation period. Conditional on this path, the state was simulated by Euler–Maruyama with step size and independent Brownian increments. After each step, the state was restricted to componentwise and projected onto .
The initial state was , implying . The regime path was fixed to regime 1 on and regime 2 on . The observation standard deviations were , and negative noisy observations were truncated at zero. The observation period was , with 201 observations at spacing 0.20. Both state components were supplied to inference and plotted. The infected population was obtained as .
D.2.5 Data-Generating Parameters and Inference Settings
Table 7 lists the data-generating SDE parameters, with regime-specific values ordered by regime; Table 8 gives the FNLE ranges, parameter-sharing structures, and priors.
Table 7: Data-Generating SDE Parameters for the Synthetic Experiments. Regime-specific values are listed for regimes 1 and 2.
| Model | Parameter | Regime 1 | Regime 2 | Structure |
|---|---|---|---|---|
| OU | 0.15 | 0.15 | shared | |
| -1.2 | 1.2 | regime-specific | ||
| 0.05 | 0.05 | shared | ||
| LV | 1.0 | 0.5 | regime-specific | |
| 1.0 | 0.5 | regime-specific | ||
| 1.0 | 0.2 | regime-specific | ||
| 1.0 | 0.2 | regime-specific | ||
| 0.05 | 0.05 | shared | ||
| 0.05 | 0.05 | shared | ||
| Gene-expression CLE | 100 | 240 | regime-specific | |
| 1.0 | 1.0 | shared | ||
| 0.004 | 0.004 | shared | ||
| 0.8 | 0.8 | shared | ||
| 0.03 | 0.03 | shared | ||
| Susceptible-infected-recovered | 0.40 | 0.80 | regime-specific | |
| 0.10 | 0.20 | regime-specific |
For all synthetic-data experiments, regime labels were aligned to the truth by choosing the permutation that minimized the root-mean-square discrepancy between posterior mean log parameters and the data-generating log parameters.
D.3 Real-Data Experiment
The real-data analysis used 71 paired observations of Didinium and Paramecium abundance from Veilleux [34]. The observations were sorted by time, the first time was shifted to zero, and both abundance variables were divided by 100 before fitting. The observation times were irregular and spanned [0, 35.08] days. The state was ordered as , where and denote Didinium and Paramecium, respectively.
The analysis used the LV model in Eq. (25). Table 9 gives the parameter-sharing structure, FNLE ranges, and priors.
For Figure 4, samples from chains 0–3 were pooled after aligning the regime labels.
D.3.1 Chain-Specific Posterior Distributions and Traces
Figure 5 compares the parameter distributions and traces from all four real-data chains.

Figure 5: Multi-chain diagnostics for the real-data Lotka–Volterra analysis. Left panels show chain-specific marginal posterior density estimates, and right panels show traces over all 10,000 sweeps. Colors distinguish the four chains; solid and dotted lines distinguish regimes 1 and 2 for regime-specific parameters. Vertical dashed lines mark the burn-in cutoff at 5,000 sweeps. The observation-noise panels show standard deviations , not variances.
Table 8: SDE Parameter Inference Settings for the Synthetic Experiments. Parameter ranges and priors are on the physical scale.
| Model | Parameter | Structure | FNLE range | Prior |
|---|---|---|---|---|
| OU | shared | [0.05, 0.2] | LogNormal(0, 1) | |
| regime-specific | [-2.0, 2.0] | Normal(0, 1) | ||
| shared | [0.01, 0.1] | LogNormal(0, 1) | ||
| LV | regime-specific | [0.01, 2] | LogNormal(0, 1) | |
| regime-specific | [0.1, 3] | LogNormal(0, 1) | ||
| regime-specific | [0.01, 2] | LogNormal(0, 1) | ||
| regime-specific | [0.1, 3] | LogNormal(0, 1) | ||
| shared | [0.01, 0.30] | LogNormal(-1, 1) | ||
| shared | [0.01, 0.20] | LogNormal(-1, 1) | ||
| Gene-expression CLE | regime-specific | [50, 400] | LogNormal(4, 1) | |
| shared | [0.5, 1.5] | LogNormal(0, 1) | ||
| shared | [0.001, 0.010] | LogNormal(0, 1) | ||
| shared | [0.5, 1.5] | LogNormal(0, 1) | ||
| shared | [0.01, 0.10] | LogNormal(0, 1) | ||
| Susceptible-infected-recovered | regime-specific | [0.05, 2] | LogNormal(0, 1) | |
| regime-specific | [0.02, 2] | LogNormal(0, 1) |
Table 9: SDE Parameter Settings for the Real-Data LV Analysis. Parameter ranges and priors are on the physical scale.
| Parameter | Structure | FNLE range | Prior |
|---|---|---|---|
| regime-specific | [0.1, 4] | LogNormal(0, 1) | |
| regime-specific | [0.01, 6] | LogNormal(0, 1) | |
| regime-specific | [0.1, 8] | LogNormal(0, 1) | |
| regime-specific | [0.01, 5] | LogNormal(0, 1) | |
| shared | [0.01, 0.8] | LogNormal(-1, 1) | |
| shared | [0.01, 2] | LogNormal(-1, 1) |
D.4 MCMC Diagnostics
Table 10: Per-parameter MCMC diagnostics for the three OU samplers on synthetic data.
| OU sampler | Parameter | Bulk ESS | Tail ESS | |
|---|---|---|---|---|
| Exact MCMC | 1.015 | 198.4 | 1,004.2 | |
| 1.004 | 1,187.8 | 6,199.0 | ||
| 1.005 | 1,478.3 | 5,050.6 | ||
| 1.004 | 1,519.8 | 2,234.7 | ||
| 1.000 | 16,311.0 | 19,035.3 | ||
| 1.000 | 16,972.1 | 18,373.4 | ||
| 1.007 | 787.0 | 1,386.9 | ||
| Approx. MCMC with FNLE (exact-transition training) | 1.011 | 323.9 | 2,294.4 | |
| 1.002 | 5,909.5 | 13,911.3 | ||
| 1.006 | 792.1 | 3,312.8 | ||
| 1.004 | 778.2 | 1,338.5 | ||
| 1.001 | 11,410.3 | 16,523.3 | ||
| 1.001 | 12,109.2 | 19,161.3 | ||
| 1.017 | 405.4 | 1,032.6 | ||
| Approx. MCMC with FNLE (Euler-Maruyama training) | 1.021 | 229.2 | 1,903.9 | |
| 1.006 | 1,497.8 | 4,256.4 | ||
| 1.004 | 2,159.5 | 7,742.9 | ||
| 1.004 | 953.9 | 1,984.0 | ||
| 1.000 | 14,125.3 | 16,715.3 | ||
| 1.000 | 12,237.1 | 19,034.8 | ||
| 1.008 | 487.4 | 838.5 |
Table 11: Per-parameter MCMC diagnostics for the synthetic Lotka–Volterra experiment.
| Parameter | Bulk ESS | Tail ESS | |
|---|---|---|---|
| 1.006 | 421.2 | 1,090.5 | |
| 1.007 | 406.2 | 777.6 | |
| 1.006 | 395.9 | 973.0 | |
| 1.006 | 385.9 | 771.1 | |
| 1.028 | 217.1 | 893.4 | |
| 1.038 | 143.4 | 301.5 | |
| 1.037 | 128.9 | 726.6 | |
| 1.048 | 107.1 | 318.3 | |
| 1.046 | 66.8 | 105.1 | |
| 1.056 | 65.5 | 45.1 | |
| 1.004 | 2,537.5 | 12,637.6 | |
| 1.006 | 1,251.7 | 5,873.1 | |
| 1.016 | 316.6 | 1,082.3 | |
| 1.016 | 400.5 | 742.1 |
Table 12: Per-parameter MCMC diagnostics for the gene-expression CLE experiment.
| Parameter | Bulk ESS | Tail ESS | |
|---|---|---|---|
| 1.003 | 805.9 | 1,595.1 | |
| 1.001 | 1,274.5 | 3,142.3 | |
| 1.011 | 211.0 | 333.4 | |
| 1.007 | 334.2 | 691.6 | |
| 1.007 | 335.3 | 681.7 | |
| 1.018 | 201.7 | 358.9 | |
| 1.000 | 16,712.8 | 18,545.4 | |
| 1.000 | 18,588.0 | 19,235.4 | |
| 1.697 | 6.2 | 11.5 | |
| 1.003 | 725.2 | 2,003.8 |
Table 13: Per-parameter MCMC diagnostics for the susceptible-infected-recovered experiment.
| Parameter | Bulk ESS | Tail ESS | |
|---|---|---|---|
| 1.019 | 481.9 | 1,013.8 | |
| 1.054 | 61.6 | 338.2 | |
| 1.065 | 66.2 | 485.9 | |
| 1.003 | 645.6 | 1,278.9 | |
| 1.000 | 15,315.1 | 18,870.5 | |
| 1.001 | 10,209.2 | 14,825.5 | |
| 1.539 | 7.0 | 41.1 | |
| 1.298 | 10.8 | 38.8 |
Table 14: Per-parameter MCMC diagnostics for the real-data Lotka–Volterra analysis.
| Parameter | Bulk ESS | Tail ESS | |
|---|---|---|---|
| 1.004 | 442.4 | 987.0 | |
| 1.005 | 929.8 | 909.5 | |
| 1.003 | 466.3 | 1,065.3 | |
| 1.005 | 871.0 | 888.9 | |
| 1.011 | 298.2 | 732.9 | |
| 1.007 | 1,160.2 | 2,167.1 | |
| 1.014 | 296.4 | 493.5 | |
| 1.004 | 1,563.6 | 3,540.1 | |
| 1.027 | 342.6 | 478.5 | |
| 1.010 | 276.9 | 552.2 | |
| 1.002 | 5,023.5 | 9,473.7 | |
| 1.002 | 3,481.9 | 7,393.4 | |
| 1.014 | 397.2 | 683.3 | |
| 1.010 | 183.5 | 344.5 |
D.5 Computing Environment and Software
D.5.1 Computing Infrastructure
All computations used only the CPU on a local PC with an Intel Core i7-1195G7 processor (4 cores, 8 threads) and 32GiB of RAM, running Ubuntu 22.04.5 LTS.
D.5.2 Software and Existing Assets
We train the local transition densities for FNLE using the NLE implementation in sbi (v0.24.0) [4]. We additionally use the Pyro package (v1.9.1) [1] for posterior sampling with NUTS. We compute and bulk and tail ESS using ArviZ (v0.22.0) [21]. All three packages are distributed under the Apache License 2.0. Complete software dependencies and their exact versions are provided in the supplementary material via the accompanying uv.lock file. The real data used in this study are publicly available in the rEDM R package (BSD 2-Clause license), originally from Veilleux [34].