---
title: 'Neural Shooting Method: Theory & Practice'
url: https://www.emergentmind.com/topics/neural-shooting-method
type: topic
---

# Neural Shooting Method: Theory & Practice

Neural shooting method denotes a family of learning, inference, and control procedures that adapt direct shooting and, more prominently, multiple shooting from numerical analysis and optimal control to neural models. Its unifying idea is to replace a single long rollout of a dynamical or deep model by shorter segmentwise solves with trainable boundary variables, and then to recover global coherence through continuity equations, penalties, augmented Lagrangians, probabilistic priors, or implicit root-finding. In current usage, the term covers multiple-shooting training of neural differential equations on oscillatory time series [2109.06786], latent state-space learning from noisy sensor data and raw images [2106.11712], differentiable multiple-shooting layers as implicit neural modules [2106.03885], shooting-based formulations of deep learning and continuous-depth networks [2006.10330], and learning-aided shooting methods for trajectory optimization [2011.10737].

## 1. Conceptual basis and optimal-control interpretation

The conceptual core of neural shooting is the distinction between **single shooting** and **multiple shooting**. In single shooting, one fixes an initial condition, integrates or iterates the learned dynamics over the full horizon, and optimizes model parameters from the resulting end-to-end loss. In multiple shooting, the horizon is partitioned, additional segment-initial variables are introduced, and the global trajectory is reconstructed by enforcing inter-segment continuity. This changes the optimization geometry: rather than forcing one parameter update to improve the fit everywhere along a long trajectory, the method allows local trajectory corrections before continuity is fully imposed [2109.06786; 2106.11712].

The optimal-control viewpoint makes this distinction precise. For a continuous problem with dynamics $\dot{x}(t)=f(x(t),u(t),t)$ and objective
$$
J[x(\cdot),u(\cdot)] \;=\; \Phi\big(x(T)\big) \;+\; \int_0^T L\big(x(t),u(t),t\big)\,dt,
$$
the Hamiltonian is
$$
H(x,u,\lambda,t) \;=\; L(x,u,t) \;+\; \lambda^{\top} f(x,u,t).
$$
A direct shooting parametrization $u(t;\theta)$ yields the adjoint gradient
$$
\frac{\partial J}{\partial \theta}
\;=\; \int_0^T \Big(\frac{\partial u}{\partial \theta}(t)\Big)^{\!\top}\frac{\partial H}{\partial u}(x,u,\lambda,t)\,dt.
$$
In the discrete Euler setting studied in "A Direct Shooting Method is Equivalent to an Indirect Method" [2003.02418], the reduced direct-shooting gradient satisfies
$$
\frac{\partial E^N}{\partial U^N}
= h
\begin{bmatrix}
\partial_u H(\lambda_0,x_0,u_0)\\
\vdots \\
\partial_u H(\lambda_{N-1},x_{N-1},u_{N-1})
\end{bmatrix},
$$
which establishes first-order equivalence between direct shooting and the indirect Pontryagin formulation.

This control-theoretic reading also recasts ordinary backpropagation. "Neural Network Training as an Optimal Control Problem: An Augmented Lagrangian Approach" explicitly identifies standard feedforward training with the sequential approach, i.e. single shooting, where state variables have been eliminated by forward propagation; the paper then motivates multiple shooting as the simultaneous alternative for mitigating ill-conditioning in deep compositions [2103.14343]. "A Shooting Formulation of Deep Learning" extends the same logic to continuous-depth networks by replacing optimization over an entire time-varying weight trajectory $\theta(t)$ with a shooting parametrization in terms of initial conditions and compatibility equations [2006.10330].

## 2. Mathematical formulations across model classes

Despite shared terminology, neural shooting appears in several mathematically distinct forms. The common structure is a set of local solves plus a mechanism that ties neighboring segments together.

| Formulation | Core variables | Continuity mechanism |
|---|---|---|
| Neural differential equations | $\theta$, shooting states $Z=\{z_k\}$ | $c_k(\theta,Z)=x_k(t_{k+1};z_k,\theta)-z_{k+1}=0$ |
| Discrete latent state-space models | $\theta$, shooting nodes $\{s_i\}$ | $s_{i+1}=f_\theta^{(n)}(s_i)$ |
| Implicit multiple-shooting layers | $B=(b_0,\dots,b_N)$ | $g_\theta(B,z_0)=B-\gamma_\theta(B,z_0)=0$ |
| Sparse Bayesian latent NODEs | block latents $\{z_b\}$ | Gaussian continuity prior with variance $\sigma_c^2 I$ |
| Condensed MS-NODE | $s$, $\theta$, auxiliary $\lambda$ | linearized KKT system for $G(s,\theta)=0$ |

In continuous-time neural ODE training, the segmentwise state on interval $[t_k,t_{k+1}]$ is defined by
$$
x_k(t)=\Phi(t;z_k,\theta),\quad t\in[t_k,t_{k+1}],
$$
with continuity constraints
$$
c_k(\theta,Z)=x_k(t_{k+1};z_k,\theta)-z_{k+1}=0.
$$
This is the formulation used to fit oscillatory time series in [2109.06786]. The same paper also considers more general neural differential equations of the form
$$
\dot{x}(t)=f\!\left(x(t),u(t),NN(x(t),u(t),t;\theta),t\right),
$$
and, for the cascading-tanks experiment,
$$
\dot{y}(t)=NN\!\big(u(t), y(t), \sqrt{y(t)}, u(t-\tau_d), \int_{t-\tau_i}^{t} u(t^\ast)\,dt^\ast; \theta\big).
$$

In discrete deterministic state-space learning from noisy measurements, the dynamics are
$$
x_{t+1}=f_\theta(x_t), \qquad y_t=g_\theta(x_t)+\epsilon_t,
$$
and multiple shooting partitions a sequence of length $T$ into $m$ intervals of length $n=T/m$. The constrained problem is
$$
\underset{s_1,\ldots,s_m,\theta}{\operatorname{argmin}}
\sum_{i=1}^{m}\sum_{k=1}^{n}
\left\|g_\theta\!\left(f_\theta^{(k-1)}(s_i)\right)-y_{(i-1)n+k}\right\|_2^2
\quad
\text{s.t.}\quad
s_{i+1}=f_\theta^{(n)}(s_i),
$$
which is then relaxed by a soft penalty [2106.11712].

Differentiable Multiple Shooting Layers formulate the problem as an implicit layer. After partitioning an IVP
$$
\dot z(t)=f_\theta(t,z(t)), \qquad z(0)=z_0,
$$
into subintervals and introducing shooting parameters $b_n$, the matching map is
$$
g_\theta(B,z_0)=B-\gamma_\theta(B,z_0),
$$
and the layer output is defined through the exact condition
$$
B^*:\; g_\theta(B^*,z_0)=0.
$$
This is neither a penalty formulation nor an augmented-Lagrangian one; it is an implicit root-finding layer with structured Jacobian [2106.03885].

A further generalization is probabilistic. In sparse Bayesian multiple shooting for latent neural ODEs, continuity between blocks is encoded by the prior
$$
p(z_{1:B}\mid \theta_{\mathrm{dyn}})
=
\mathcal{N}(z_1\mid \mu_0,\sigma_0^2 I)
\prod_{b=2}^{B}
\mathcal{N}\!\left(
z_b \,\Big|\,
\mathrm{ODEsolve}\!\big(z_{b-1},t_{[b-1]},t_{[b]},f_{\theta_{\mathrm{dyn}}}\big),
\,\sigma_c^2 I
\right),
$$
which turns continuity control into a KL-regularized variational objective rather than a deterministic feasibility requirement [2210.03466].

## 3. Constraint enforcement and optimization mechanisms

The dominant design choice in neural shooting concerns how continuity is enforced. The simplest approach is a quadratic penalty. For neural differential equations, the penalty objective is
$$
J(\theta,Z)=\mathcal{L}_{\text{data}}(\theta,Z)+\frac{\rho}{2}\sum_{k=0}^{K-1}\|c_k(\theta,Z)\|^2.
$$
The main drawback is the classical one: too small a $\rho$ leaves persistent shooting gaps, whereas too large a $\rho$ causes numerical ill-conditioning and training stalls [2109.06786].

A more robust alternative is the augmented Lagrangian,
$$
\mathcal{L}_{\text{AL}}(\theta,Z,\lambda;\mu)
=
\mathcal{L}_{\text{data}}(\theta,Z)
+\sum_{k=0}^{K-1}\lambda_k^\top c_k(\theta,Z)
+\frac{\mu}{2}\sum_{k=0}^{K-1}\|c_k(\theta,Z)\|^2,
$$
with multiplier updates
$$
\lambda_k^{(m+1)}=\lambda_k^{(m)}+\mu^{(m)}\,c_k\big(\theta^{(m)},Z^{(m)}\big).
$$
This is the mechanism used in oscillatory neural ODE fitting [2109.06786] and in the layerwise optimal-control formulation of DNN training, where an outer augmented-Lagrangian loop is combined with Gauss-Newton inner solves and a forward dynamic programming solver for the block-tridiagonal linear least-squares systems arising from the multiple-shooting constraints [2103.14343].

Discrete latent state-space learning from noisy images and sensors adopts a pure penalty form,
$$
l(s_1,\ldots,s_m,\theta)
=
\frac{1}{mn}\sum_{i=1}^{m}\sum_{k=1}^{n}
\left\| g_\theta\!\left(f_\theta^{(k-1)}(s_i)\right)-y_{(i-1)n+k}\right\|_2^2
+
\frac{\alpha}{m-1}\sum_{i=1}^{m-1}
\left\|s_{i+1}-f_\theta^{(n)}(s_i)\right\|_2^2,
$$
optimized with Adam over both global parameters and trajectory-specific shooting nodes. The reported schedule initializes $\alpha=1$, increases it once after 200 epochs to $10^2$–$10^4$ depending on the task, reinitializes the optimizer, and reduces the learning rate by $\times 10$ at that point; another decay occurs at epoch 600 [2106.11712].

More recent work has emphasized first-order-compatible exact enforcement. In condensed MS-NODE training, the stacked equality constraints $G(s,\theta)=0$ are linearized and the reduced system
$$
(G_sG_s^\top+G_\theta G_\theta^\top)\,\Delta\lambda
=
G-G_sL_s-G_\theta L_\theta
$$
is solved for an auxiliary increment $\Delta\lambda$, after which $\Delta s$ and $\Delta\theta$ are recovered and passed to Adam. The stated purpose is to incorporate shooting equality constraints while training a multiple-shooting neural ordinary differential equation using first-order optimization methods such as Adam, without tuning penalty weights [2506.00724].

Gradient computation likewise varies by formulation. Continuous-time methods may differentiate through the ODE solver segmentwise, use forward sensitivities, or integrate adjoint equations. Whole-brain dynamic causal modeling combines multiple shooting with an adjoint implementation called Adaptive Checkpoint Adjoint, chosen to preserve numerical consistency between forward and backward passes under noisy observations [2102.11013]. Differentiable Multiple Shooting Layers instead exploit the nilpotent block-lower structure of $D\gamma_\theta(B^*)$ to compute implicit gradients efficiently, and also provide a forward-sensitivity formulation in which $v(t)=D\phi_\theta(z,s,t)$ satisfies
$$
\dot v(t)=D f_\theta (t,z(t))v(t), \qquad v(s)=I_{n_z},
$$
allowing segment sensitivities to be obtained in one solver call [2106.03885].

## 4. Empirical domains and representative results

A central empirical driver for neural shooting has been failure of single shooting on oscillatory or long-horizon dynamics. In neural ODE time-series fitting, standard single-shooting training can converge to a flattened, low-frequency trajectory that cuts through oscillations rather than tracking them; the paper attributes this to spectral bias, long-horizon sensitivity, and poor local minima. Multiple shooting with penalty or augmented Lagrangian resolves this behavior on both a synthetic spiral and a real cascading-tanks dataset. In the spiral example, single shooting with Nadam at learning rate $0.001$ fails to capture oscillations, whereas multiple shooting with $20$ intervals and an augmented-Lagrangian method with LBFGS successfully fits the data and generalizes to $t\in[0,250]$ despite training only to $t=6$. In the cascading-tanks experiment, multiple shooting with Bayesian-optimized $\rho_{l_2}=5.96\times 10^{-2}$, $\tau_d=79.0~\mathrm{s}$, and $\tau_i=164.0~\mathrm{s}$ achieves average square-root error $0.42$ on training, $0.50$ on validation, and $0.62$ on test [2109.06786].

The same stability advantage appears under indirect and noisy observations. In the discrete multiple-shooting state-space framework, the method is reported as robust to noisy measurements and able to handle chaotic systems. On pendulum images with Gaussian pixel noise $\sigma=0.2$, test performance averaged over 1000 trajectories reached MSE $0.0154 \pm 0.0026$ for SSM-FC and $0.0152 \pm 0.0022$ for SSM-LL, with BCE $0.2902 \pm 0.0075$ and $0.2895 \pm 0.0064$ respectively. On Moving MNIST, the method trained stably on $2$ million images and $200{,}000$ shooting nodes, obtaining BCE $353.3$ for the reported SSM-LL configuration. On partially observed noisy Lorenz trajectories of length $T=10{,}000$, ten-step prediction MSE for SSM-RNN improves from $3592.27$ at $T=10$ to $0.154$ at $T=10{,}000$, and the learned dynamics reproduce the Lorenz strange attractor under long iteration of $f_\theta$ [2106.11712].

In computational neuroscience, the Multiple-Shooting Adjoint method extends the paradigm to whole-brain dynamic causal modeling. On large-scale linear systems with $p\in\{10,20,50,100\}$ compartments, the reported mean squared error $(\times 10^{-3})$ between estimated and ground-truth parameters is $0.7\pm0.1$, $0.9\pm0.3$, $0.8\pm0.1$, and $0.8\pm0.2$ for MSA, whereas EM is reported as $3.3\pm0.2$ and $3.0\pm0.2$ for 10 and 20 nodes and out-of-memory for 50 and 100 nodes. The same framework is applied to fMRI from 82 children with ASD and 48 controls, where time-resolved effective-connectome features estimated by MSA yield better accuracy, F1, and ROC-AUC than functional connectome features for both Random Forest and InvNet classifiers [2102.11013].

Neural shooting has also been used as a computational primitive rather than merely a training trick. Multiple Shooting Layers are presented as drop-in replacements for Neural ODEs and Neural CDEs. In latent sequence generation they are reported to require **60% less NFEs** during both training and inference while maintaining equivalent sample quality to Latent Neural ODEs; in Neural CDE training on PhysioNet 2019 sepsis, total wall-clock time is reported as **one order of magnitude smaller** while preserving AUROC trends; and for Timoshenko beam boundary control they are reported as **three times faster than the sequential rk4 with same accuracy (step size)** [2106.03885].

In trajectory optimization, Neural-iLQR uses shooting over the unconstrained control space but replaces an inaccurate model with a learned local neural model. In numerical simulation, conventional model-based iLQR achieves objective values $10192$ for vehicle tracking and $1642$ for cartpole, while Neural-iLQR achieves $992.9$ and $1178$. In MuJoCo cartpole with model inaccuracy, iLQR fails at 40% and 60% mismatch, whereas Neural-iLQR remains successful with objective values $3.458$ and $3.038$ (reported as Obj.Val $\times 10^3$) [2011.10737].

## 5. Relation to adjacent methods and recurrent misconceptions

A recurrent misconception is that neural shooting is merely heuristic trajectory splitting. Several formulations are explicitly principled. The equivalence result for direct and indirect shooting shows that the direct reduced gradient and Hamiltonian stationarity encode the same first-order conditions [2003.02418]. Sparse Bayesian multiple shooting replaces ad hoc stitching by a well-defined probabilistic continuity prior and an ELBO with closed-form Gaussian KL terms [2210.03466]. The augmented-Lagrangian and condensed-KKT formulations likewise treat continuity as a constrained optimization problem rather than an informal regularizer [2103.14343; 2506.00724].

A second misconception is that neural shooting is synonymous with continuous-time neural ODE training. The literature is broader. The discrete state-space model of [2106.11712] contains no numerical ODE solve; per-segment “integration” is $n$ repeated applications of $f_\theta$. Multiple shooting has also been used for feedforward neural networks interpreted as finite-horizon optimal-control systems [2103.14343], for implicit layers [2106.03885], and for shooting-based parametrization of continuous-depth or even discrete-time networks via particle ensembles [2006.10330].

A third misconception is that continuity must always be enforced by large quadratic penalties. The literature contains at least five distinct mechanisms: quadratic penalties and augmented Lagrangians for neural differential equations [2109.06786]; soft penalties in discrete latent state-space models [2106.11712]; exact root-finding in implicit multiple-shooting layers [2106.03885]; Gaussian continuity priors in Bayesian latent neural ODEs [2210.03466]; and condensed linearized KKT solves designed for first-order optimizers such as Adam [2506.00724].

Neural shooting is also closely related to, but not identical with, collocation and two-stage smoothing. The oscillatory NODE paper contrasts multiple shooting with two-stage approaches that first fit a spline and estimate derivatives, noting that such methods require all states to be measured and degrade with noise or sparsity [2109.06786]. The same paper observes that collocation enforces both dynamics and continuity algebraically at grid points, while multiple shooting solves IVPs on segments and enforces only segment matching; this often yields better conditioning and simpler parallelization for oscillatory dynamics [2109.06786]. In latent neural ODE training, the Bayesian multiple-shooting paper argues that heuristic sub-trajectory training or progressive lengthening lacks principled continuity control and underperforms its blockwise probabilistic formulation, especially on irregular grids [2210.03466].

## 6. Limitations, tuning parameters, and current research directions

The main practical degrees of freedom are segment length, number of segments, initialization of shooting variables, and continuity strength. Across formulations, shorter segments improve stability by reducing gradient path length, integration drift, or repeated composition of an untrained transition model, but increase the number of auxiliary variables and the burden of satisfying continuity. The oscillatory neural ODE study uses $K=20$ intervals on $[0,6]$ and explicitly notes interval-length effects as future work [2109.06786]. The discrete latent state-space model recommends segment lengths $n\in[10,100]$ as a stability–efficiency compromise [2106.11712]. Sparse Bayesian multiple shooting reports a “sweet spot” for block size and shows that overly strong continuity, i.e. very small $\sigma_c$, can cause collapse on complex data [2210.03466].

Another persistent issue is the trade-off between optimization robustness and computational overhead. Multiple shooting introduces auxiliary variables such as $Z$, $\{s_i^j\}$, multipliers, or block latents, and each iteration typically solves many local IVPs. This cost is often acceptable because segments are independent and highly parallelizable, but it can still be memory-intensive. The discrete state-space model notes that storing many shooting nodes can be expensive and suggests streaming datasets and on-the-fly node management as future improvements [2106.11712]. Multiple Shooting Layers achieve large speedups in full-batch settings through one-step fixed-point tracking, but the paper explicitly states that mini-batch SGD breaks the tracking assumption [2106.03885].

Noise, partial observability, and identifiability remain central challenges. The DCM work emphasizes that deconvolution, fixed hemodynamic response functions, and high-dimensional effective-connectivity estimation may require structural priors or regularization [2102.11013]. The latent state-space formulation separates dynamics learning from deployment-time inference and therefore requires either probabilistic filtering such as UKF or a learned encoder such as CNN-LSTM to infer latent states from observations [2106.11712]. Bayesian multiple shooting addresses part of this issue with amortized inference through a transformer-based recognition network with temporal attention and relative positional encoding, but its performance remains sensitive to encoder design and posterior variance flooring [2210.03466].

Current research directions therefore cluster around better constraint handling, better inference, and better scalability. Proposed directions include augmented Lagrangian or SQP alternatives to manually tuned penalties in latent state-space learning [2106.11712], adaptive segmentation and principled continuity schedules [2106.11712; 2506.00724], stronger first-order-compatible equality handling through condensing [2506.00724], joint training of inference modules with shooting-based latent dynamics [2106.11712], and incorporation of controls, heteroscedastic or non-Gaussian observation models, Hamiltonian or symmetry structure, and sensor-fusion constraints [2106.11712; 2210.03466]. A broader implication is that neural shooting has evolved from a stabilization technique for long-horizon fitting into a general design pattern for differentiable constrained dynamical learning, spanning parameter estimation, latent representation learning, optimal control, and implicit neural architectures.

Source: https://www.emergentmind.com/topics/neural-shooting-method