arXiv:2611.05157cs.LGNov 2026

Manuscript Offprint

arXiv:2611.05157

Macrocanonical Generator Networks: Data-Efficient Neural Surrogates for Amortized Physics Simulation

Niall Jeffrey, Benjamin D. Wandelt

Abstract

Many scientific simulations are computationally expensive, limiting their use in simulation-based inference, uncertainty quantification, and decision making. We introduce macrocanonical generator networks, a framework for learning fast, data-efficient neural surrogates for amortized simulation of stationary physical processes by matching multiscale statistics of a target process. Inspired by microcanonical maximum-entropy synthesis, which matches feature statistics per sample by inner-loop optimization, our approach instead trains a neural generator to satisfy the same constraints in expectation, preserving physically realistic sample-to-sample fluctuations. We prove that gradient-descent training induces preconditioned gradient-descent dynamics in sample space that inherit the symmetry-preservation properties of the microcanonical gradient descent of Bruna and Mallat, amortizing its per-sample inner-loop optimization into a single training run after which every sample is generated in one forward pass. We further show that residual generator parameterizations initialized near the identity, trained with a small learning rate, preserve entropy locally during early optimization and mitigate mode collapse. Experiments on cosmology and fluid simulations show that macrocanonical generators recover realistic samples from extremely small training sets, in some cases a single training example, while generating new realizations more than 10610^{6} times faster per sample than the reference simulator and more than 10310^{3} times faster than microcanonical gradient descent. The trained generators can be reused for downstream pretraining, including simulation-based inference, providing a data-efficient route to multi-fidelity scientific machine learning workflows.

1 Introduction

Scientific simulations are essential tools for understanding complex physical systems. However, high-fidelity simulators are often computationally expensive, sometimes requiring days to generate a single realization because each sample typically requires an iterative solve or stochastic rollout. This limits their use in tasks such as simulation-based inference [2, 7], uncertainty quantification, and decision making, where large numbers of simulations are required. Examples include cosmological simulation [33, 17], tsunami models [3], wind farm simulation [18], and nuclear fusion models [14].

Recent advances in deep generative modelling have demonstrated that neural networks can learn complex data distributions. Methods such as generative adversarial networks [9], diffusion models [13], and normalizing flows [31] have achieved remarkable success in image generation and related domains. Earlier work such as Generative Moment Matching Networks [21] trains generators by matching the empirical data distribution using the maximum mean discrepancy (MMD). However, these methods typically rely on large training datasets and are not designed for settings in which

40th Conference on Neural Information Processing Systems (NeurIPS 2026).

Figure

Figure 1: Macrocanonical generator networks (centre) turn a small set of expensive simulator outputs (left; turbulence and cosmology targets, Section 5) into large ensembles of new realizations matching the chosen statistical features (e.g. wavelet phase harmonics) of the targets, unlocking downstream scientific machine-learning tasks (right) that are intractable with the expensive simulator alone.

only a small number of simulator realizations are available, a regime that is common in scientific computing.

Other moment-matching approaches, such as MMD-GAN [20], the method of simulated moments [25] and turbulence closures [28], as well as neural operators (which address the different task of predicting a simulator's output for given boundary conditions), likewise require many simulations or observations, whereas we match a fixed multiscale moment vector (features) that a single stationary realization can be sufficient to estimate.

Many physical processes of interest—turbulent flows, cosmological fields, multifractal processes—are stationary: their statistical properties are invariant under spatial translations. This stationarity is a powerful inductive bias. As shown by Bruna and Mallat [4], the translation symmetry of a stationary process means that a single realization of dimension dd provides O(d)O(d) translated copies of local structures, enabling accurate estimation of statistical moments from as few as a single example.

In such systems, knowledge about the process is naturally expressed through statistical constraints. Multiscale statistics derived from wavelet transforms, scattering transforms [1, 5], or wavelet phase harmonics [23, 35] can capture important non-Gaussian structure in complex signals. Throughout, “multiscale” refers to spatial scales rather than temporal, and all signals considered are equal-time snapshots. Classical texture synthesis methods exploit this structure by generating samples that match these statistics [29]. In these approaches, samples are synthesized individually by optimizing pixel values until the target statistics are satisfied. This procedure can be interpreted as a form of microcanonical maximum-entropy sampling [4, 35], where the probability distribution is conditioned on the empirical statistics of the observed signal. Related recent work extends moment-constrained generation with diffusion-based samplers that guide moments along stochastic trajectories toward maximum-entropy models [19]. These approaches remain per-sample iterative at generation time.

In this work we introduce macrocanonical generator networks, a neural framework that generalizes this idea. Instead of synthesizing each realization independently through optimization, we train a neural generator that produces samples whose statistics match those of the target process in expectation. The generator therefore learns a global transport map that produces samples satisfying the desired statistical constraints. Moreover, enforcing constraints in expectation rather than per sample is a better match to real physical processes, in which individual realizations fluctuate around their defining statistics (Section 2.2).

This shift from per-sample optimization to learning a global generator has important consequences. Once trained, the generator acts as a fast surrogate simulator capable of producing large numbers of realizations in one forward pass per sample, effectively amortizing the expense of iterative simulation and iterative moment-guided sampling. In this sense, our objective is complementary to trajectory-based approaches: rather than improving a per-sample iterative sampler, we learn a reusable transport map for high-throughput workflows. Because the training objective depends on statistical constraints rather than individual examples, and because stationarity provides abundant constraints from few realizations, the method can operate effectively in extremely data-limited regimes. The resulting generators can be used to pretrain neural networks for downstream tasks, enabling new approaches to simulation-based inference [2, 7], multi-fidelity modelling [12], and the training of scientific foundation models [27, 24, 34].

Beyond the practical advantages, the macrocanonical formulation provides a conceptual bridge between classical statistical synthesis methods and modern deep generative modelling. In particular, we show that training such generators induces a preconditioned gradient descent dynamics in sample space, closely related to the optimization procedure used in microcanonical synthesis [4, 35]. Two design choices are key: (i) residual generator parameterizations initialized near the identity, and (ii) sufficiently low learning rates. Together, these help the generator preserve entropy locally during early optimization and mitigate collapse to degenerate outputs. Without these inductive biases, the generator can collapse toward a constant mapping F(x)≈y∗F(x) \approx y^*, effectively giving the same output for every input, which is a situation of near-minimal entropy.

Table 1: Macrocanonical generator networks (ours) compared with prevailing deep generative methods and with classical microcanonical synthesis. Properties marked “exact, by construction” follow from architectural equivariance and the loss; properties marked “approximate (learned)” hold only insofar as the training set is large and diverse enough to make them statistically apparent.

Macrocanonical (ours)GANDiffusion modelMicrocanonical synthesis
Training samples needed≥1\geq 1 realizationlarge datasetlarge dataset≥1\geq 1 realization
Inference cost per sample1 forward pass1 forward passmany (∼102−3\sim 10^{2-3}) stepsinner-loop optimization
Symmetries of moment constraintsexact, by constructionapproximate (learned)approximate (learned)exact, by construction
Per-realization fluctuationsyes (constraints in expectation)yesyesno (Dirac on ϕ∗\phi^*)
Training signalfeature-moment matchingadversarialdenoising score matchingper-sample feature matching
Distributional flexibilitylimited to constrained momentsunrestrictedunrestrictedlimited to constrained moments

The main contributions of this work are therefore:

(i) We introduce macrocanonical generator networks, a generative framework that learns neural transport maps producing samples whose feature statistics match those of a target process while replacing per-sample iterative simulation or sampling with amortized one-pass generation after training.

(ii) We establish a connection between neural generator training and microcanonical synthesis, showing that generator training induces preconditioned gradient descent dynamics.

(iii) We analyze the entropy behavior of residual generators and show that identity-initialized residual parameterizations with low learning rates help to preserve local volume and maintain diversity in generated samples, while generators without these inductive biases suffer from mode collapse.

(iv) We demonstrate that macrocanonical generators can learn effective surrogate simulators in extremely data-limited regimes, including cases with a single training example, leveraging the stationarity of the target process as a key inductive bias and making many-query analyses with surrogate simulators computationally practical.

(v) We show how such generators can be used for pretraining in simulation-based inference pipelines, enabling new multi-fidelity workflows and providing a potential foundation for training scientific foundation models.

Together, these results suggest that macrocanonical generator networks provide a new framework for constructing fast neural surrogate simulators of stationary physical processes, bridging ideas from statistical physics, classical synthesis methods, and modern deep generative modelling.

Table 1 compares macrocanonical generators with the most widely used deep generative model classes and classical microcanonical synthesis. The framework trades distributional generality for three properties that are important in the data-limited scientific regime: (i) training from a handful, or even a single, realization; (ii) by-construction preservation of every symmetry respected by the moment constraints, rather than approximate symmetry learned from data; and (iii) amortized one-pass generation, like a GAN and unlike a diffusion model.

References (31)