Spatial Autoregressive Variational Distributions
- Spatially autoregressive variational distributions are models that incorporate spatial dependence via structured covariance and autoregressive latent orderings.
- They combine graph-based precision formulations with localized factorization methods to accurately capture spatial dependencies in diverse applications.
- This approach enables scalable inference by balancing computational efficiency with the preservation of spatial correlations in latent representations.
Searching arXiv for the cited papers to ground the article in current literature. Spatially autoregressive variational distributions are variational families in which the approximate posterior or latent distribution is organized so that dependence follows a spatial, graph, or locality-preserving structure rather than an exchangeable or fully factorized one. In recent work, this idea appears in several distinct but related forms: Gaussian variational posteriors whose precision is the sum of restricted-likelihood and spatial precision terms in ICAR models, checkerboard-ordered local factorizations for object catalogs in astronomical images, and variable-length autoregressive latent chains that retrieve spatially grounded information for control (Thakur, 8 Apr 2026, Regier, 3 Oct 2025, Zhu et al., 9 Jul 2026). Related formulations use matrix-variate normal latents to encode spatial structure explicitly, variational autoencoders trained on CAR samples to emulate spatial random effects, and variational autoregressive networks for lattice systems (Wang et al., 2017, Wang et al., 18 Mar 2025, Liu et al., 2024).
1. Conceptual foundations
The term “spatially autoregressive” does not identify a single variational family. In graph-based spatial statistics, it refers to variational distributions whose covariance or precision inherits adjacency structure from a spatial weights matrix or graph Laplacian. In Gaussian ICAR/CAR models, one starts from an adjacency matrix , a degree matrix , and a graph Laplacian . Proper CAR uses a positive-definite precision, often of the form with , whereas ICAR takes , so is singular for connected graphs because and (Thakur, 8 Apr 2026).
In spatial detection and other neural settings, “autoregressive” instead refers to an ordering of spatial latent variables or tiles. In astronomical detection, the latent space is partitioned by a -color checkerboard pattern, and the variational family factorizes over color classes,
0
with within-rank conditional independence and local conditioning chosen to mirror the posterior Markov blanket induced by finite object radius and additive image formation (Regier, 3 Oct 2025).
In continuous-control reasoning, spatial organization can be present without a fixed grid factorization. Latent Memory Palace formulates a variable-length discrete autoregressive latent sequence 1, terminated by EOS, and describes “spatial organization” as a learned space navigated sequentially while the encoder and decoder cross-attend to spatially structured observation embeddings from image encoders. The latent prior itself is sequential rather than grid-indexed, but each latent step can retrieve and focus on spatially localized cues through attention (Zhu et al., 9 Jul 2026).
A further generalization appears in variational autoregressive networks for statistical mechanics, where a spatial configuration 2 is ordered into a sequence and modeled as
3
Here the “spatial” content is controlled by the ordering, with raster, zigzag, spiral, or space-filling curves such as Hilbert or Z-order curves used to preserve locality on lattices (Liu et al., 2024).
2. Graph-precision formulations in spatial statistics
The most explicit spatially autoregressive variational distributions arise when the variational covariance is tied directly to a spatial precision. In VREML for Gaussian ICAR models, the variational family is a Gaussian on the constrained subspace 4,
5
and the ELBO on the restricted likelihood simplifies to
6
The defining property is that the optimal variational precision is
7
so the spatial autoregressive precision 8 appears both in the ELBO and in the variational covariance itself. Under Gaussian 9 and an ICAR prior on 0, the conditional posterior 1 is Gaussian on 2 with the same precision and mean 3; consequently, the variational family is exact and the ELBO is tight (Thakur, 8 Apr 2026).
Spatial error models provide a related but distinct construction. In the SEM,
4
with 5, the induced covariance is 6 and the spatial precision is 7. Variational Bayes with missing responses uses Gaussian variational approximations with factor covariance,
8
or a hybrid factorization
9
Although the variational covariance is low-rank-plus-diagonal rather than explicitly sparse-precision, spatial dependence enters the optimization through 0, 1, and the exact conditional
2
which is used by HVB under MAR (Wijayawardhana et al., 2024).
The same SEM backbone has been extended to non-Gaussian settings by combining Student’s 3-distributed errors with the Yeo–Johnson transformation. The paper introduces SEM-t, YJ-SEM-Gau, and YJ-SEM-t, and develops VB and HVB estimators based on a Gaussian variational approximation with factor covariance and reparameterized constrained parameters 4, 5, 6, and 7. In these models, the spatial autoregressive structure continues to operate through 8, the determinant term 9, and quadratic forms such as 0 or 1 (Wijayawardhana et al., 29 May 2025).
A further generalization appears in unrestricted panel SAR models. The spatial lag is represented by a learned 2 spillover matrix 3 in
4
and variational Bayes is carried out row-by-row in two stages. Stage 1 estimates 5 with Gaussian 6 for 7 and a learned precision matrix 8 for the first-stage errors. Stage 2 estimates
9
with Gaussian 0 for 1. Dirichlet–Laplace priors induce sparsity in both 2 and 3, yielding closed-form variational updates for Gaussian, Gamma, inverse Gaussian, and generalized inverse Gaussian factors (Gefang et al., 2022).
3. Matrix-normal and autoencoded spatial latents
Spatial variational auto-encoding via matrix-variate normal distributions provides a different route to spatially structured variational inference. Instead of vector latents, the latent variable is a feature map 4 with
5
The Kronecker covariance 6 imposes a separable spatial structure on the latent feature map, with 7 controlling covariance across rows and 8 across columns. Within the VAE ELBO,
9
the KL against a standard normal prior reduces to a Gaussian KL with 0, and the paper develops a low-rank mean parameterization 1 that reduces encoder outputs from 2 to 3 per collection of 4 latent maps of size 5. The paper explicitly notes that it does not use AR(1) Toeplitz or GMRF/SAR precision structures, but also states that such autoregressive covariance choices are natural extensions of the MVN framework (Wang et al., 2017).
Variational autoencoded multivariate spatial Fay–Herriot models move the spatial autoregressive burden into a learned generator. In the separable MCAR case,
6
which the paper rewrites as
7
A 8-VAE is then trained on samples from the CAR prior, with latent standard normal 9 and decoder 0. After training, the decoder is fixed and reused as a prior emulator for spatial random effects on the same geography. For VSMS-FH, the implementation uses 1; for VGMS-FH, two decoder draws are combined through the GMCAR structure
2
with 3. Spatial dependence is therefore not imposed by an explicit variational precision during downstream inference; it is learned from samples generated with 4, using 5 during VAE training (Wang et al., 18 Mar 2025).
These matrix-normal and autoencoded constructions shift attention from sparse-precision exactness to amortized spatial structure. One uses explicit covariance algebra in latent feature maps, and the other uses a learned decoder as a reusable generator of spatial effects.
4. Checkerboard and memory-palace autoregression
In high-dimensional perception and control, spatially autoregressive variational distributions are often built around locality and conditional independence rather than sparse Gaussian precision. For object detection in astronomical images, the latent catalog is tiled spatially and split into tiles of interest 6. Because object contributions are local—7 when 8—the posterior has a local Markov structure. The variational family uses a 9-color checkerboard partition with rank
0
and factorizes as
1
For a posterior locality radius 2 and tile size 3, the minimal number of colors is 4. Within each tile, an auxiliary permutation 5 gives
6
This yields a variational graph that mirrors the posterior conditional independencies while preserving GPU parallelism within each color class (Regier, 3 Oct 2025).
Latent Memory Palace adopts a variable-length discrete autoregressive latent sequence rather than a tiled field. With observation 7, action chunk 8, latent vocabulary 9, and termination time 0, the model uses
1
with decoder 2. The latent sequence is interpreted as an iterative retrieval path in a learned “memory palace.” The paper emphasizes that this is not a PixelCNN-style factorization over a fixed image grid and not an explicit geometric graph. Instead, latent steps form a route through a learned space, and spatial grounding is supplied by cross-attention to visual observation tokens and positional embeddings. The resulting latent path is therefore sequential in its prior factorization but spatial in what it retrieves (Zhu et al., 9 Jul 2026).
These two examples illustrate a central distinction. In the checkerboard family, spatial autoregression is made explicit by coloring and neighborhood conditioning. In the memory-palace family, spatial structure is implicit in the retrieval mechanism and the observation embeddings, while autoregression governs the order and length of latent reasoning.
5. Optimization, training criteria, and inference mechanics
The optimization of spatially autoregressive variational distributions is as diverse as their parameterizations. In VREML, the ELBO admits closed-form coordinate-ascent updates: 3
4
The paper proves that each block is strictly concave, the ELBO is monotone nondecreasing under block updates, and any accumulation point is a stationary point (Thakur, 8 Apr 2026).
Astronomical SAVD is trained not by an ELBO on observed data but by Neural Posterior Estimation under the expected forward KL. The objective is
5
with unbiased gradient
6
The paper stresses the contrast between forward and reverse KL: forward KL is mode-covering and better aligned with calibration for ambiguous blends, while the autoregressive tiling ensures that the variational graph matches the posterior’s locality (Regier, 3 Oct 2025).
LMP uses neither continuous reparameterization nor Gumbel-softmax. Because discrete autoregressive sampling blocks direct reparameterization, the ELBO is optimized by latent-space reinforcement learning. The KL term decomposes stepwise,
7
which yields per-step rewards. Stable updates use a PPO-style clipped surrogate with length-aware clipping, prior mixing, and per-step free-nats. Adaptive halting is induced by a decoder variance schedule 8, so extra latent steps are useful only when they improve the reconstruction mean enough to offset tighter variance (Zhu et al., 9 Jul 2026).
For variational autoregressive networks in statistical mechanics, the objective is variational free energy rather than a standard data ELBO. With target Boltzmann distribution 9, minimizing 00 is equivalent to minimizing
01
The natural-gradient update uses the Fisher information
02
and, in low-rank sample space, becomes
03
This changes the dominant inversion from parameter dimension 04 to batch size 05, giving complexity cubic in batch size rather than in model parameters (Liu et al., 2024).
Missing-data spatial models often require hybridization. In SEMs under MAR or MNAR, HVB factorizes as 06 or its MNAR analogue and draws 07 by exact Gaussian conditionals, block Gibbs, or Metropolis–Hastings proposals embedded inside the variational loop. This approach is used both in Gaussian SEMs and in non-Gaussian YJ-SEM and 08-SEM variants (Wijayawardhana et al., 2024, Wijayawardhana et al., 29 May 2025). In unrestricted panel SAR, the corresponding hybridization is algebraic rather than stochastic: two-stage VB decomposes the spatial simultaneous system into first-stage instrument construction and second-stage row-wise estimation, with Dirichlet–Laplace shrinkage making the updates closed form (Gefang et al., 2022).
6. Empirical behavior, misconceptions, and open questions
Empirical results show that the benefit of spatially autoregressive variational structure depends strongly on whether the underlying task is governed by local dependence, adjacency-constrained smoothness, or multimodal spatial retrieval. In Xenium breast cancer spatial transcriptomics, VREML reports RMSE 09 and MAE 10, compared with Exact REML 11, 12, MLE 13, 14, and INLA 15, 16. The same paper states that VREML is “exact under Gaussian ICAR settings,” so the empirical advantage is computational and numerical rather than an approximation gap in 17 (Thakur, 8 Apr 2026).
In astronomical detection, the checkerboard autoregressive structure is tied directly to calibration. On held-out synthetic SDSS-like data, log-likelihood of ground-truth catalogs improves from 18 for 19 to 20 for 21, and F1 improves from approximately 22 to 23. In the crowded M2 setting, log-likelihood improves from 24 to 25, and F1 improves from approximately 26 to 27. The paper repeatedly attributes these gains to reduced border artifacts and better calibration near tile boundaries (Regier, 3 Oct 2025).
In control, LMP-28 and LMP-29 connect spatial retrieval to adaptive test-time compute. On DROID zero-shot tasks, LMP-30 reports block-bowl 31 versus 32 for DP and marker-mug 33 versus 34. On finetuned DROID tasks, it reports peg-hole 35 versus 36, and clean-table 37, 38, 39 values of 40 versus 41, 42 versus 43, and 44 versus 45. On LIBERO-90 multitask, average performance is 46 versus 47, and bottom-10 tasks are 48 versus 49. The paper further reports a negative correlation 50 between average latent steps and KNN action variance, and interprets this as linking adaptive compute to irreducible uncertainty (Zhu et al., 9 Jul 2026).
Autoencoded spatial priors in Fay–Herriot models are motivated primarily by scalability. In Missouri simulations, SMS-FH requires about 51 hours per simulation and VSMS-FH about 52 minutes, while GMS-FH requires about 53 hours and VGMS-FH about 54 minutes. In California, the paper states that GMS-FH would require more than 55 days for one simulation, whereas VGMS-FH requires about 56 hours and VSMS-FH about 57 hours per simulation on GPU. The empirical pattern reported is that the VAE-based models preserve most of the spatial benefit of MCAR or GMCAR structure while making tract-scale multivariate estimation computationally feasible (Wang et al., 18 Mar 2025).
For SEMs with missing data, the main practical lesson is that variational structure alone is not always sufficient. Under MAR with 58 and 59 missing, JVB gives 60 and 61, whereas HVB-G gives 62 and 63. Under MNAR with the same dimensions and missingness, HVB-AllB and HVB-3B give 64 and 65, versus JVB 66. In the non-Gaussian SEM literature, YJ-SEM-t is reported to provide the best fit for skewed heavy-tailed data, while YJ-SEM-Gau is often nearly as competitive at lower computational expense (Wijayawardhana et al., 2024, Wijayawardhana et al., 29 May 2025).
Two recurrent misconceptions are explicitly rejected by this literature. First, spatially autoregressive variational inference is not synonymous with gridwise factorization: LMP states that its latent autoregression is “over sequence positions that represent a navigable route in memory, not fixed spatial coordinates,” while SAVD uses color classes and local neighborhoods rather than a pixelwise raster. Second, variational inference in spatial models is not always inexact: in Gaussian ICAR restricted-likelihood estimation, the optimal Gaussian variational family coincides with the true restricted posterior (Zhu et al., 9 Jul 2026, Regier, 3 Oct 2025, Thakur, 8 Apr 2026).
Open directions are stated in several papers. LMP identifies sensitivity to RL hyperparameters, latent collapse, and the cost of larger vocabularies and longer horizons, and suggests continuous latent chains, persistent latents across an episode, and hierarchical spatial-temporal factorizations. SAVD notes exposure bias in NPE, the trade-off between larger 67 and sequential cost, and possible extensions through multi-scale tilings or learned neighborhoods. The SEM and panel-SAR papers emphasize scalability of blocked MCMC, weak-instrument issues, and the possibility of variational families with sparse-plus-low-rank precisions that mirror the spatial operator more directly. A plausible implication is that future work will continue to move between two poles: exact or near-exact variational families tied to spatial precision operators, and amortized neural families that learn spatial dependence from data while sacrificing direct probabilistic structure (Zhu et al., 9 Jul 2026, Regier, 3 Oct 2025, Wijayawardhana et al., 2024, Gefang et al., 2022).