WorksPhysics and Astronomy
A generative foundation model for 2D magnetized plasma turbulence
Abstract
We present a proof-of-principle study demonstrating a conditional generative foundation model for self-organizing magnetized plasma turbulence. Built on a multichannel flow-matching framework with a spectral decomposition strategy, the model is trained on direct numerical simulations of 2D modified Hasegawa-Wakatani (MHW) turbulence across the hydrodynamic to adiabatic parameter range. Without retraining, this single model successfully performs three distinct downstream tasks: (i) unconditional generation of statistically faithful quasi-steady-state snapshots that recover the directional energy spectra and amplitude statistics, from which statistical transport quantities, including turbulent flux and effective diffusivity, alongside their uncertainties, are inferred directly; (ii) super-resolution from and downsampled observations to reconstruct fine-scale turbulence and large-scale zonal structures; and (iii) full-field inpainting from sparse spatial observations covering as little as of the domain. The generated fields faithfully reproduce regime-dependent turbulence vs. zonal-flow states and energy partitioning. Under extreme sparsity the long-correlation zonal flows are pinned by only a handful of observations, while the residual uncertainty concentrates in the small-scale turbulent fluctuations. These results establish flow-matching generative models as powerful, unified surrogates for state generation, statistical inference, and sparse-data reconstruction, providing a scalable baseline for 3D plasma turbulence and experimental applications.
Introduction
Magnetized plasma turbulence and its nonlinear interaction with self-generated mean flows, in particular zonal flows, govern cross-field transport in essentially every magnetic-confinement fusion device and underlie the formation of transport barriers and confinement transitions[1]. A predictive understanding of this turbulence-flow interplay is therefore essential for fusion reactor design and operation, but is made difficult by the extreme range of spatial and temporal scales, the strongly nonlinear and chaotic character of the dynamics, and the high cost of high-fidelity gyrokinetic or fluid simulations.
For the past four decades, reduced fluid models of drift-wave turbulence have provided a tractable yet physically meaningful setting in which to study these phenomena. The Hasegawa-Wakatani (HW) model[2] in its original form describes resistive drift-wave turbulence in a magnetized slab through two coupled equations for the perturbed density and the electrostatic potential. In the modified Hasegawa-Wakatani (MHW) model[3], the resistive coupling is restricted to the non-zonal components of the fields, thus allowing the spontaneous generation of stable zonal flows through turbulent Reynolds stresses and the subsequent suppression of cross-field transport. The MHW model thus retains, within a minimal two-field 2D system, the essence of drift-wave-zonal-flow interaction. Its two asymptotic limits, hydrodynamic at small adiabaticity and quasi-adiabatic at large adiabaticity, bracket two regimes of practical interest: nearly isotropic turbulence and strongly anisotropic turbulence-zonal-flow states[3]. Statistical and phase-transition properties of HW/MHW turbulence have continued to attract attention[4, 5].
Recent years have seen rapid adoption of machine learning (ML) in plasma physics, ranging from data-driven closures[6, 7] and surrogate models[8] to disruption predictors[9]. The HW/MHW family has served as a test bed for many of these developments, including data-driven rediscovery of the model equations from simulation data[10], non-intrusive reduced-order modelling[11], calibration of coarse-grid dissipation against high-fidelity turbulence statistics[12], and neural-operator surrogates that capture the bifurcating drift-wave and zonal-flow dynamics[5]. However, conventional supervised learning approaches face fundamental challenges in turbulence modeling: they are deterministic (unable to sample from the conditional distribution of turbulent states) and task-specific (a model trained for forward prediction cannot perform inference or reconstruction without retraining). Generative models address these limitations by learning the full data distribution rather than a point map, enabling (i) ensemble sampling with uncertainty quantification, (ii) conditioning on partial observations for inverse problems without task-specific retraining, and (iii) potential generalization across regimes. Generative approaches have begun to enter plasma turbulence research, through GAN-based deconvolution for large-eddy simulations[13] and variational autoencoder-based generative surrogates for long-time transport simulations[14]. In parallel, generative models such as diffusion models[15] and the more recent flow-matching framework[16] have rapidly matured into powerful tools for high-fidelity reconstruction, super-resolution and inpainting in hydrodynamic turbulence[17, 18, 19, 20, 21]. However, these plasma applications remain task-specific and single-regime. A unified conditional generative foundation model for magnetized plasma turbulence, one that spans turbulence regimes and serves state synthesis, statistical inference, and sparse-data reconstruction within a single learned prior, and captures the coexistence and competition between self-generated zonal flows and small-scale drift-wave turbulence, has so far been lacking.
In this work, we present a proof-of-principle study of a generative foundation model for magnetized plasma turbulence, using the 2D MHW system as a controlled testbed. We build a single conditional generative model on direct numerical simulations spanning the full hydrodynamic-to-adiabatic range, using a multichannel flow-matching model[20] augmented with a spectral decomposition strategy[18] to mitigate spectral bias and capture multiscale dynamics. The trained model demonstrates three key capabilities: it unconditionally synthesizes statistically faithful turbulent state realizations that recover regime-dependent energy spectra and zonal-flow morphology, from which statistical transport quantities such as the turbulent particle flux are inferred directly, and the same trained model supports two practically important conditional reconstruction tasks—physical-state super-resolution from heavily downsampled low-resolution fields, and full-field reconstruction from spatially sparse observations without any task-specific retraining or finetuning. In addition, we characterize how reconstruction uncertainty is distributed across scales under extreme observation sparsity: zonal flows are readily pinned by sparse observations due to long correlation lengths, while higher uncertainty concentrates in small-scale turbulent fluctuations. These results have implications for plasma diagnostics and data assimilation in more realistic experimental settings.
The remainder of the paper is organized as follows. Section II introduces the MHW equations, outlines the simulation campaign and the construction of the training and evaluation datasets. Section III describes the multichannel flow-matching generative model used in this study. Section IV presents the unconditional-generation and transport-inference results, the super-resolution and inpainting results, and the generalization to adiabaticity values not used in training, together with quantitative assessments of statistical fidelity. Section V summarizes the findings and discusses open issues and future directions.
Physics models and data generation
The modified Hasegawa–Wakatani system
We consider the 2D MHW model in a doubly periodic slab with Cartesian coordinates , where denotes the radial direction and is the binormal/poloidal direction. Under the standard drift-wave normalization, the model evolves the fluctuating plasma density and electrostatic potential according to
where is the vorticity, is the standard Poisson bracket, is the adiabaticity parameter, is the normalized background density gradient, and the terms model small-scale hyper-dissipation.
A field is decomposed into its zonal (flux-surface-averaged) and non-zonal (fluctuating) components via and . Restricting the resistive coupling to the non-zonal components is the key MHW modification, since the zonal components are constant on a flux surface () and therefore do not drive the parallel electron current that the resistive coupling represents.
The system admits two quadratic invariants under ideal dynamics:
i.e. the total energy (a sum of kinetic and internal energy) and the generalized enstrophy . The MHW system is linearly unstable for any finite when numerical dissipation is neglected[3]; for the parameters scanned in this work (, ), the linear dispersion relation gives maximum growth rates at and , peaking near . Nonlinearly, the MHW system has two asymptotic limits: the hydrodynamic limit () where the density and vorticity equations decouple and the dynamics reduces to 2D Navier-Stokes-like turbulence driven by the linear instability, producing nearly isotropic small-scale turbulence, and the adiabatic limit () where the resistive coupling forces , yielding a Hasegawa-Mima-like regime dominated by drift-wave-zonal-flow interaction.
Direct numerical simulations
Training and evaluation data are generated with the GDB code[22], which solves Eqs. (1) and (2) on a doubly periodic square domain of physical size (in units of ) at a numerical resolution of . The spatial discretization uses the Arakawa scheme for the nonlinear Poisson brackets, a pseudospectral treatment for the hyper-diffusion operators (sixth order, , with in normalized units), and the trapezoidal leapfrog time integrator with in normalized time units.
In this study, we fix the normalized background density gradient at and scan the adiabaticity parameter over in increments of 0.1. For each , the simulation is run from random initial perturbations through the linear-growth phase into a statistically stationary saturated state, which is reached within the first normalized time units. Snapshots of are then recorded at intervals of one time unit throughout the saturated phase, yielding a retained record of 20,000 snapshots per case. In addition, three simulations at adiabaticity values not used in training, and (within the training range) and (beyond it), are performed with the same numerical setup and saturation procedure. They serve only as references for the zero-shot tests of Section IV E, and none of their snapshots enters the training set.
Pre-processing and dataset splits
Each snapshot is downsampled to by retaining every fourth grid point in each direction, balancing computational efficiency with resolution of energy-containing scales across all regimes. The density and potential channels are normalized independently to using per- min-max scaling computed from the training dataset. This normalization is applied consistently during training and inference, and inverted for all post-hoc physical diagnostics. Critically, the train-test split is performed temporally rather than randomly: the first 18,500 snapshots from each case (spanning the initial portion of the saturated phase) form the training set, while the final 1,500 snapshots (from later in the saturated phase) are withheld entirely and reserved for evaluation. This temporal split ensures that training and evaluation cover non-overlapping time intervals, providing a more stringent test of generalization than random splitting from a single time window. Unlike many data-driven approaches that randomly shuffle training and test samples from the same temporal ensemble, our protocol better reflects the challenge of predicting future or unseen transient realizations of turbulent dynamics.
Generative foundation model: multichannel flow matching with conditional guidance
Optimal transport flow-matching framework
Flow matching[16] is a generative modeling approach for learning complex data distributions through a continuous normalizing flow. The key idea is to construct a deterministic sample path that evolves from a tractable base distribution (e.g., a standard Gaussian) at pseudo-time to the target data distribution at . Here, represents a spatiotemporal field (in our case, the turbulent density and potential contours), and its evolution is governed by a learned neural velocity field :
where is a standard Gaussian (the base distribution) and is prior conditioning information (e.g., adiabaticity parameter , discussed above). At , samples generated by integrating this ODE converge to the data distribution .
Training uses optimal-transport (OT) flow matching, which specifies a linear interpolation path between and :
where and . The velocity field is trained to minimize
Compared to diffusion models, flow matching offers two practical advantages: (i) the regression target in Eq. (6) is simple and simulation-free (no noise schedule or score-matching formulation is needed), and (ii) the straight-line OT paths are efficient to integrate, typically requiring fewer function evaluations at inference time. The vector field is parameterized by a U-Net-style convolutional architecture with sinusoidal embeddings for pseudo-time and learned embeddings for the conditioning variable . At inference, samples are generated by solving Eq. (5) from a random Gaussian seed using a standard ODE integrator (e.g., forward Euler or RK45). The full architectural and training details are provided in Appendix C.
Multichannel spectral decomposition
To jointly model the coupled dynamics of the two MHW fields (, ), we adopt the multichannel flow-matching formulation of Parikh et al. ²⁰. A naive two-channel representation would allow the network to learn their joint distribution and capture cross-correlations between density and potential fluctuations, which is a necessary feature since the MHW dynamics couple and through the adiabaticity parameter (Eqs. (1)–(2)). However, this direct two-channel approach suffers from a critical normalization imbalance: the energy-containing scales of (low wavenumbers) dominate the dynamic range of the channel, causing small-scale fluctuations (high wavenumbers) to be numerically suppressed when both fields are normalized independently to during training. This underrepresentation of small-scale potential structure prevents the network from accurately learning the multiscale, coupled physics of the system.
We address this by decomposing into low and high-wavenumber components before normalization, thereby mitigating the spectral bias inherent in neural networks trained on normalized data. Define the box wavenumber and introduce two overlapping Fourier masks:
where in this study. The corresponding spatial components are
where is the Fourier transform.
Modes satisfying appear in both channels. This overlap is essential: it eliminates sharp spectral discontinuities at the cutoff wavenumber , which would otherwise introduce training artifacts and impair the network’s ability to learn smooth, scale-dependent variations in the dynamics. The three normalized channels are then supplied to the flow-matching network. This ensures that small-scale potential fluctuations receive representational weight comparable to large-scale features during training, rather than being drowned out by energy-containing scales. The effectiveness of this spectral decomposition strategy is validated in Appendix B, where ablations show that omitting the decomposition results in degraded high-wavenumber fidelity in both unconditional samples and conditional reconstructions across all regimes, a direct consequence of unmitigated spectral bias.
Prior conditioning: classifier-free adiabaticity guidance
The adiabaticity parameter encodes the regime of plasma turbulence via the prior conditioning variable (). During training, is represented as a learned scalar embedding that is fused with the pseudo-time embedding before being passed to the U-Net backbone.
We employ classifier-free guidance[23], a training-time strategy that enables the same network to learn both conditional and unconditional distributions without requiring a separate classifier or likelihood model. Specifically, the conditioning is randomly removed (i.e., set to zero or a null embedding) with probability during training. This forces the network to learn both
Classifier-free guidance offers several practical advantages over classifier-based guidance (which would require training a separate classifier network or loss): (1) No additional model or likelihood computation is needed; all information flows through the single velocity field . (2) The network learns to condition on amortized within a single training objective, avoiding the need for task-specific retraining when switching between conditional and unconditional modes. (3) Because is treated as a continuous scalar rather than a discrete class label, the learned conditional distribution can be queried at adiabaticity values not encountered during training, enabling zero-shot interpolation and extrapolation (Section IV E).
At inference, regime-specific samples are generated by providing the corresponding value to the network. Unconditional samples are obtained by omitting the signal, which samples from the learned marginal .
Posterior conditioning: flow-guided measurement assimilation
Inverse problems are naturally formulated as Bayesian posterior inference: given a measurement acquired under a known state-to-observable operator , we seek samples from
where is our learned prior (conditional or marginal, depending on whether is known).
We employ a measurement-guided posterior sampling strategy, in the spirit of diffusion posterior sampling (DPS)[24], that combines the learned flow prior with gradient-based guidance[25]. At each pseudo-time step along the sampling trajectory, we use Tweedie’s estimate to predict the implied data-space target:
This prediction is then used to compute a measurement consistency loss:
The gradient is used to steer the sampling ODE towards the posterior:
where is a fixed scaling coefficient and prevents division by zero. The adaptive rescaling in Eq. (14) normalizes the measurement gradient to the magnitude of the model’s velocity, ensuring that the likelihood correction remains balanced with the prior drift throughout the sampling trajectory. Without this rescaling, the measurement gradient would either overwhelm the prior dynamics (when large) or be negligible (when small), both pathologies that degrade posterior fidelity[25].
The modified ODE is integrated using forward Euler with uniform steps (). Independent Gaussian seeds yield an ensemble of posterior samples, which we report as ensemble means with per-pixel variance to quantify reconstruction uncertainty.
No network retraining is required to apply this posterior sampling strategy to new measurement operators . The learned velocity field remains fixed; only the measurement operator and its gradient change. This enables immediate transfer to new inverse problems, a key feature of the proposed foundation model for practical scientific applications where data assimilation problems frequently change.
Downstream tasks
The trained flow-matching network, together with the posterior-sampling strategy above, enables three distinct downstream tasks without modification:
Task 1: Unconditional generation. Samples are drawn directly from the learned prior by integrating Eq. (5) with a random seed and no measurement guidance (). This produces statistically representative turbulent states that reflect the learned data distribution at a specified adiabaticity , or when conditioning is omitted. Ensemble statistics of nonlinear functionals of the fields, e.g., the turbulent particle flux (Section IV B), are evaluated directly on these samples.
Task 2: Super-resolution. The measurement operator uniformly downsamples the target field by a factor of :
Given a low-resolution observation , the posterior sampler reconstructs a high-resolution field consistent with this coarse measurement, inferring the fine-scale structure from the learned prior.
Task 3: State inpainting. The measurement operator applies a binary spatial mask :
where denotes element-wise multiplication. The posterior sampler then reconstructs the full field from partial spatial observations, inferring unobserved regions from the learned prior while respecting the pixel values where observations are available.
Both conditional tasks (Tasks 2 and 3) use the same pre-trained flow-matching backbone without task-specific retraining, realized through the guided sampling scheme of Eq. (14). This is a core feature of foundation models: a single prior learned on diverse training data can be flexibly reused for downstream tasks with minimal additional computation.
Results
We organize the results as follows. Section IV A establishes, through unconditional sampling, that the model has correctly learned the regime-dependent statistics of the MHW system. Section IV B shows that statistical transport quantities and their uncertainties can be inferred directly from the generated ensembles. Section IV C demonstrates physical-state super-resolution from and downsampled fields, and Section IV D full-field reconstruction from spatially partial observations, characterizing how the reconstruction uncertainty is distributed across scales. Section IV E examines generalization to adiabaticity values not used in training.
All results are evaluated on snapshots withheld from the model’s training, as described in Sec. II C. For unconditional generation, we draw independent samples for each adiabaticity value and compare their ensemble statistics with held-out DNS snapshots from the corresponding case.
For posterior reconstruction, each measurement is selected from a held-out DNS snapshot. Super-resolution measurements are obtained by uniformly downsampling the reference field by factors of 4 and 8, corresponding to observed resolutions of and , respectively. Sparse-observation measurements are formed by retaining a prescribed fraction of spatial locations from the reference field. Unless otherwise stated, the same measurement operator is applied to both the density and potential channels. For each fixed measurement, 300 posterior samples are generated from independent Gaussian initializations while keeping the observation unchanged. Throughout the figures, and denote the full fluctuating fields modelled by the network, including their zonal components; the zonal/non-zonal decomposition of Section II A enters only the resistive coupling term.
Sampling the learned prior across adiabaticity regimes
We first assess whether the model has captured the regime-dependent structure of the MHW system by drawing samples at each trained value of the adiabaticity parameter and comparing them against held-out simulation snapshots. The comparison proceeds from qualitative flow structure to quantitative statistics: two-dimensional contours, directional energy spectra, point-wise probability density functions (PDFs), and a distribution-level embedding of the full sample sets. As shown in Figure 1, the generated samples reproduce the characteristic transition of the MHW system: at , both the density and potential fields exhibit nearly isotropic small-scale turbulence, whereas at the fields are dominated by zonally elongated bands. The generated samples are visually indistinguishable from the reference snapshots, indicating the model successfully synthesizes diverse turbulent states.
Figure 1. Density (top row) and potential (bottom row) contours of a reference (ref.) snapshot and four unconditionally generated (gen.) samples at (a) and (b) . The full doubly periodic ( units) domain is shown; the color scale is shared across the panels of each row.
To quantify the fidelity of the generated fields scale by scale, we compare the 1-D total energy density spectra and (Eq. (18)) between the generated ensemble and the reference statistics at and (Figure 2).
Figure 2. Total energy density spectra (left column) and (right column) at (top row) and (bottom row). Dashed black lines denote the reference simulation statistics; solid red lines denote the mean over unconditionally generated samples, with shaded bands indicating the ensemble spread.
At , the generated spectra follow the reference across the full resolved wavenumber range in both directions, with a slight energy deficit at wavenumbers (). At , the model is able to capture discrete peaks in associated with the dominant zonal-flow wavenumbers, indicating that the learned prior encodes the nonlinear zonal wavelength selection of the saturated state. However, the generated spectra flatten at wavenumbers (, ), over-predicting the reference tail. This discrepancy is due to a known spectral bias issue of generative models[26], which recover low-frequency content preferentially and leave a residual noise floor at small scales. The residual is more visible at . because the saturated turbulence is roughly two orders of magnitude less energetic than at , so the high- reference energy decays to levels comparable with this noise floor. The kinetic and internal energy spectra are shown separately in Appendix B (Figure 15), which also quantifies the benefit of the spectral decomposition for the high-wavenumber floor.
Figure 15. Spectra of unconditional samples with and without spectral decomposition. Columns show the density spectra , and kinetic-energy spectra , ; rows correspond to (top) and (bottom). Each panel compares the reference statistics with the sample mean one standard deviation from the spectral-decomposition model (red) and the baseline model trained without spectral-decomposition (blue).
Beyond second-order spectral statistics, we also compare the one-point amplitude statistics of the fluctuations. As shown in Figure 3, the generated PDFs of and closely follow the reference in both regimes. Notably, the low-probability tails are recovered down to densities of for both cases, with only minor tail deviations in at , confirming that the high-wavenumber noise floor noted above does not distort the amplitude statistics of the fields.
Figure 3. Point-wise PDFs of density (left) and potential (right) fluctuations at (blue) and (red). Dashed lines denote reference simulation data and solid lines denote unconditionally generated samples.
Finally, we examine whether the generated ensemble covers the reference distribution at the level of the entire dataset, rather than aggregated statistics from individual cases.
Figure 4 shows a joint t-SNE embedding of reference and generated samples across all ten trained values of . The samples organize into well-separated clusters by , and within every cluster the generated samples (crosses) interleave with the reference samples (circles) rather than forming a displaced or contracted sub-cluster. This indicates that conditioning on reliably steers generation to the correct regime, without sign of either mode collapse or memorization. The clusters for adjacent in the strong zonal-flow range () lie closest in the embedding, which is consistent with the underlying physics as the system approaches the adiabatic limit.

Figure 4. Joint t-SNE embedding of reference (circles) and unconditionally generated (crosses) snapshots for all trained values of .
Inference of statistical transport quantities
Because the model learns the joint distribution of conditioned on the adiabaticity , statistical transport quantities that are nonlinear functionals of both fields can be evaluated directly on unconditionally generated ensembles, without the model ever having been trained on them. The primary quantity of interest is the radial turbulent particle flux
where is the radial velocity and denotes the average over the full domain, together with the effective turbulent diffusivity obtained from the imposed background gradient; since in this study, coincides numerically with and only is reported below. Evaluating Eq. (15) over an ensemble of generated snapshots at each yields not only the mean flux but its full distribution, and hence a data-free estimate of the transport level and its intrinsic variability.
Figure 5 shows the particle flux as a function of for the ten trained values. The DNS shows a strong reduction in radial transport as increases. The decrease is particularly sharp between and , where drops by nearly one order of magnitude, followed by a more gradual decay toward the adiabatic regime. As the zonal flow becomes dominant, turbulent radial transport is strongly suppressed. The generated ensemble closely follows both the magnitude and the nonlinear dependence of on , including the sharp transport reduction around . The predicted mean is lower than the DNS value at all ten values of , by 1 to 12%, but the discrepancy remains small compared with the overall variation of the flux across regimes.
Figure 5. Particle flux versus the adiabaticity parameter for the ten training cases. The generated ensemble (red) is compared against the DNS reference (black dashed, time-averaged); error bars denote standard deviation of the per-snapshot mean flux over each ensemble.
Furthermore, Table I compares the statistical quantities obtained from the DNS and generated ensembles across all trained values of . The model reproduces the kinetic and internal energies (Eqs. (19) and (21)), their zonal components (Eqs. (20) and (22)), the generalized enstrophy (Eq. (23)), and the particle flux (Eq. (15)) to within 15% over the full parameter range, with two exceptions: the enstrophy is over-predicted at every (by up to 23%), consistent with the high-wavenumber noise floor noted in Section IV A, and the zonal internal energy at , where it is only 4% of , is over-predicted by about 70%. More importantly, it captures the strong redistribution of energy associated with the transition toward the adiabatic regime. As increases, the zonal kinetic energy becomes an increasingly large fraction of the total kinetic energy, while the internal energy and turbulent particle flux decrease substantially. The ensemble spreads are not reproduced as well as the means: the generated spread is smaller than the DNS spread for and (by a factor of 0.5 to 0.95) and larger for , and (by up to a factor of 4), so the spread of the generated ensemble should be read as a measure of variability rather than as a calibrated uncertainty. This agreement indicates that the generated fields preserve not only marginal field statistics, but also the regime-dependent energy partition between turbulent fluctuations and self-organized zonal structures.
Super-resolution from 4 and 8 downsampled observations
We now impose posterior conditioning, taking to be a uniformly decimated observation of the target field that retains every fourth or eighth grid point (effective resolutions of and ). Figure 6 and Figure 7 compare the resulting posterior samples with the reference fields and with a deterministic bicubic-interpolation baseline at and ; the corresponding energy spectra are shown in the two left columns of Figure 8.
Figure 6. Super-resolution reconstruction contour of density field from and uniformly downsampled measurements at (a) and (b) . Left to right: reference, measurement, bicubic interpolation reconstruction, two posterior generated samples, and absolute differences of the bicubic reconstruction and of each posterior sample.
Figure 7. Super-resolution reconstruction contour of potential field from and uniformly downsampled measurements at (a) and (b) . Left to right: reference, measurement, reconstruction with bicubic interpolation, two posterior generated samples, and absolute differences.
Figure 8. Total energy density spectra and of DPS reconstructions (red) versus bicubic interpolation (blue) and the reference (black dashed), for and uniformly downsampled measurements and 10% and 25% sparse observations: (a) , (b) .
The contour comparison (Figure 6 and Figure 7) shows that bicubic interpolation recovers only the large-scale organization of the flow, returning overly smooth fields in which the fine-scale eddies are often absent. In contrast, the posterior samples restore small-scale structure consistent with the learned turbulence prior.
For the density field, at downsampling the observation still constrains most of the energy-containing scales, and the reconstructions are visually nearly indistinguishable from the reference in both regimes, with correspondingly small absolute differences. At downsampling the reconstructions are no longer pixel-wise exact. This is not a shortcoming of the model but a direct consequence of posterior sampling, since many high-resolution fields are consistent with the same observation and individual posterior draws realize different instances of the unresolved scales.
| Model | |||||||
| 0.1 | DNS | ||||||
| GenAI | |||||||
| 0.2 | DNS | ||||||
| GenAI | |||||||
| 0.3 | DNS | ||||||
| GenAI | |||||||
| 0.4 | DNS | ||||||
| GenAI | |||||||
| 0.5 | DNS | ||||||
| GenAI | |||||||
| 0.6 | DNS | ||||||
| GenAI | |||||||
| 0.7 | DNS | ||||||
| GenAI | |||||||
| 0.8 | DNS | ||||||
| GenAI | |||||||
| 0.9 | DNS | ||||||
| GenAI | |||||||
| 1.0 | DNS | ||||||
| GenAI |
Table 1. Statistical quantities of the DNS reference and the generative model across –: kinetic energy , zonal kinetic energy , internal energy , zonal internal energy , enstrophy , and particle flux , domain-averaged and reported as mean standard deviation over 300 DNS frames and 300 generated samples per case.
The potential field at (Figure 7(b)) is a notable special case in which all reconstructions, including the bicubic baseline, closely match the reference with uniformly small errors; the only conspicuous bicubic artifact is a columnar error along the domain edge at , where non-periodic interpolation is inconsistent with the doubly periodic topology that the learned prior respects automatically. In the near-adiabatic regime is dominated by large-scale zonal structures, so nearly all of its energy resides in modes that survive even decimation. Super-resolution of is therefore intrinsically easier than that of the density field, whose small-scale content carries a larger share of the energy.
The total energy density spectra in Figure 8 highlight the distinction between bicubic interpolation and conditional generation quantitatively. The DPS reconstructions follow the reference up to – at both factors, beyond which the same high-wavenumber noise floor as in Section IV A appears, most visibly in at ; bicubic interpolation departs from the reference by one to two orders of magnitude beyond the wavenumber of the coarse grid.
Inpainting from partially observed fields
We next consider inpainting, in which is a partial observation of the field, either a contiguous observation window or randomly placed points, and the model completes the surrounding flow. Figure 9 and Figure 10 show reconstructions of the density and potential fields from a centered square region covering 50% and 10% of the domain at and .
Figure 9. Inpainting contour comparison of from a centered observed region covering 50% (top) and 10% (bottom) of the domain, at (a) and (b) . Left to right: reference, measurement, two posterior generated samples, and the absolute difference of each posterior sample.
Figure 10. Inpainting contour comparison of from a centered observed region covering 50% (top) and 10% (bottom) of the domain, at (a) and (b) . Left to right: reference, measurement, two posterior generated samples, and the absolute difference of each posterior sample.
Within the observed window the posterior samples reproduce the measurement faithfully, and only small amplitude residuals remain in the absolute-difference panels. These residuals reflect the soft nature of the conditioning in Eq. (14), where measurement consistency is imposed through the gradient of the misfit rather than by exact replacement of the observed pixels, so the observations are matched only up to the tolerance of the guided dynamics.
Outside the window the samples depart substantially from the reference realization, because the turbulence decorrelates within a few structure sizes and the unobserved region admits many valid realizations. Crucially, the generated structures connect to the observed region without visible discontinuity at the window boundary. Each sample is therefore a physically plausible realization consistent with the measurement. Figure 11 extends the analysis to randomly placed point observations and quantifies the posterior uncertainty along a horizontal line cut, with the ensemble mean and a band
Figure 11. Posterior uncertainty of DPS reconstructions from randomly observed pixels along a horizontal line cut. Each row shows a reference snapshot followed by reconstructions from 5%, 10%, 25%, and 50% randomly observed pixels.
(pixel-wise standard deviation ) computed from repeated posterior draws at observation fractions of 5%, 10%, 25%, and 50%. First, the uncertainty band contracts monotonically as the observation fraction increases, for both fields and both regimes, as the posterior concentrates around the true realization. Second, at the uncertainty remains low wherever zonal structures dominate, even at the sparsest observation level. Because these coherent structures possess long correlation lengths, a few observed pixels suffice to pin them across the entire domain, whereas the fine-scale eddies of the hydrodynamic regime remain uncertain between sensors. The right two columns of Figure 8 confirm that reconstructions from 10% and 25% random observations likewise recover the reference energy spectra up to –3, with the same high-wavenumber floor, closing the comparison presented in Section IV C.
Zero-shot predictions on unseen
We next examine whether the learned model can generalize to adiabaticity values that are not included during training. We consider and for interpolation within the training range, and for extrapolation beyond the largest training value. During inference, these values are supplied directly through the continuous embedding, without retraining or fine-tuning. Figure 12 shows that prior samples at all three unseen values reproduce the main regime-dependent flow morphology observed in the corresponding DNS. In particular, the model captures the change from more disordered turbulence at to increasingly pronounced zonal organization at and . This indicates that the learned conditioning is not restricted to the discrete values encountered during training.
Figure 12. Zero-shot unconditional generation at unseen adiabaticity values , , and . The cases and lie within the training range, while lies outside the training range.
However, the agreement is weaker when the generated ensembles are compared through their total energy spectral density. As shown in Figure 13, the model reproduces the overall spectral shape and the dominant zonal peaks, but noticeable errors remain at the lowest modes for all three unseen values. These modes contain the largest-scale structures of the flow and are strongly dependent on . Although the training dataset contains many turbulent realizations at each condition, the dependence on is sampled at only ten discrete values. The scalar label therefore provides relatively insufficient information for identifying the precise statistical distribution at an unseen condition. Interpolation of the conditioning embedding can recover the qualitative regime and dominant structures, but does not determine the correct energy partition among the lowest wavenumbers.
Figure 13. Total energy density spectra (top row) and (bottom row) at unseen adiabaticity values , , and . Dashed black lines denote the reference simulation statistics; solid red lines denote the mean over unconditionally generated samples, with shaded bands indicating the ensemble spread.
The situation changes substantially once partial field measurements are introduced through DPS. Figure 14 compares the reconstructed spectra with bicubic interpolation for the same three unseen values of . Across both super-resolution and sparse-observation settings, the DPS reconstructions recover the reference spectra more faithfully than the bicubic baseline. Specifically, the improvement is clear beyond the scales directly resolved by the measurements, where bicubic interpolation flattens while the generative reconstruction retains the turbulent spectral decay up to –, beyond which the high-wavenumber floor noted above sets in.
Figure 14. Total energy density spectra and of DPS reconstructions (red) versus bicubic interpolation (blue) and the reference (black dashed), for and uniformly downsampled measurements and 10% and 25% sparse observations at unseen adiabaticity values: (a) , (b) , and (c) .
Notably, small localized spectral spikes are visible in some super-resolution cases, most clearly near for the case. These features are associated with the discrete measurement constraint rather than with a physical turbulent mode. Uniform decimation constrains the reconstruction only on a regularly spaced sampling lattice, while the unresolved values between measurement points remain inferred from the learned prior. Strong DPS guidance toward exact consistency on this lattice can therefore introduce a weak grid-scale imprint in the reconstructed field, which appears as a narrow spectral excess at intermediate wavenumbers. The artifact is small relative to the broadband spectra and decreases as the observations provide stronger constraints on the unresolved field.
The improvement brought by the measurements highlights the complementary roles of parameter conditioning and physical observations. The scalar label identifies the approximate turbulence regime, but by itself does not specify which region of the conditional state distribution should be sampled. The measurements provide realization-specific information and substantially reduce this ambiguity. Therefore, they constrain the posterior toward the part of the learned manifold that is consistent with the actual flow state, even when the supplied was not encountered during training. As the observation density increases, the posterior becomes more strongly constrained and the reconstructed spectra approach the DNS reference. This trend is visible when moving from to super-resolution and from 10% to 25% spatial observations.
Summary and outlook
We have presented a proof-of-principle study of generative AI applied to magnetized plasma turbulence, in which a single multichannel flow-matching model with a spectral decomposition strategy was trained on 2D modified Hasegawa-Wakatani simulations spanning the full hydrodynamic-to-adiabatic parameter range. The trained model serves a triple role: it unconditionally generates statistically faithful quasi-steady-state snapshots that reproduce regime-dependent energy spectra and zonal-flow morphology, from which the turbulent particle flux and the regime-dependent energy partition are inferred directly; it performs physical-state super-resolution from heavily downsampled fields (4 and 8); and it reconstructs the full fields from spatially sparse observations down to coverage. The learned conditioning also extends to adiabaticity values not used in training, qualitatively tively for unconditional samples and quantitatively once measurements are supplied. To our knowledge this is the first demonstration that a conditional generative foundation model can simultaneously capture small-scale drift-wave turbulence and the coexisting self-generated zonal flow within a single learned prior, and provide both reconstruction and uncertainty estimates without task-specific retraining.
Several limitations of the present work, and corresponding directions for follow-up, are worth highlighting. First, the present study is restricted to a single 2D fluid model in a small periodic box and to quasi-steady-state snapshots; extension to (a) the original HW model and other reduced models, (b) 3D and gyrofluid systems, and (c) the transient and bursty regimes, e.g., LH-like and ELM-like dynamics, are natural next steps. Second, our reconstruction uses static snapshots; conditioning on temporal context, or jointly modelling the spatio-temporal dynamics, would likely improve the reconstruction of the small-scale turbulence under sparse observations and enable a true forecasting mode of operation. Third, the model is trained on numerical data with known physics; testing on experimental measurements, e.g., 2D imaging diagnostics on tokamaks or stellarators, and comparison against existing reduced-order and operator-learning approaches will be necessary to establish utility for routine plasma diagnostics. Fourth, a particularly attractive target in this direction is cross-field inference. Unlike the PINN-based approach[27], which requires knowledge of the underlying governing equations or an approximation of them, in our study, because the learned prior is joint over , observations of the density channel alone, the quantity most readily imaged experimentally, can in principle constrain posterior samples of the unobserved potential, and hence of the flow and the turbulent flux; quantifying the fidelity of such density-to-potential reconstruction is a natural next experiment within the present framework. Finally, under extreme observational sparsity the fine-scale content remains under-determined between sensors, whereas the long-correlation zonal component is pinned by even a few observations. Recovering this small-scale content in the sparse limit may benefit from temporal context or physics-informed conditioning, for instance through constraints derived from the conservation laws.
Taken together, our results suggest that flow-matching-based generative models offer a flexible, regime-agnostic foundation for plasma-turbulence diagnostics, sparse-data reconstruction, and statistical inference, and constitute a promising step toward generative foundation models for the broader class of self-organizing magnetized plasma systems.
Acknowledgments
This work was supported by the U.S. Department of Energy (DOE) Genesis Mission under DE-SC0026662. This research used resources of the National Energy Research Scientific Computing Center, a DOE Office of Science User Facility supported by the Office of Science of the U.S. DOE under Contract No. DE-AC02-05CH11231 (FES-ERCAP 0036750 and DDR-ERCAP0039129). The authors would also like to acknowledge the support from the NVIDIA Academic Grant Program with the use of NVIDIA RTX PRO 6000 GPUs and NVIDIA CUDA Toolkit.
Data Availability Statement
The data that support the findings of this study are available from the corresponding author upon reasonable request.
Definitions of physical quantities
We summarize here the physical diagnostics used throughout the quantitative evaluation. In Fourier space, the potential, kinetic, and total energy densities are defined as
The corresponding domain-averaged quantities are
where and quantify the kinetic and density energy contained in the zonal components. We further evaluate the generalized enstrophy,
together with the radial turbulent particle flux defined in Eq. (15). These diagnostics are computed for both DNS and generated ensembles and are used to assess the fidelity of the learned joint distribution beyond point-wise field statistics.
The effectiveness of spectral decomposition
In this section, we evaluate the statistical fidelity of unconditionally generated states and isolate the contribution of the spectral-decomposition strategy introduced in Section III. For each of the ten trained adiabaticity values we compare the spectra following the same protocol as in Section IV A. As shown in Figure 15, both models reproduce the potential energy density spectra and over the entire resolved range and agree with the reference despite minor deviations after . However, the kinetic spectra from the baseline model flatten beyond , whereas the spectral decomposition model shows decent alignment with the reference for both and . The improvement is confined to because only the potential is split into low- and high-wavenumber channels, and the steep decay of leaves its small scales near the normalization floor where the weighting of amplifies any residual error.
Network architecture and training details
The flow-matching vector field is parameterized by a U-Net with a base channel width of 128 and channel multipliers across five resolution levels. Each level contains two residual blocks, and multi-head self-attention with eight heads is applied at spatial resolutions 8, 16, and 32. The model uses a noise scale of . Training uses the Adam optimizer with an initial learning rate of and a cosine-annealing schedule over 40 epochs. The batch size is 40, distributed across eight GPUs. At inference, the probability-flow ODE is integrated using 200 forward-Euler steps.
References
References
- [1]¹P. H. Diamond, S.-I. Itoh, K. Itoh, and T. S. Hahm, Plasma Phys. Control. Fusion 47, R35 (2005).
- [2]²A. Hasegawa and M. Wakatani, Phys. Rev. Lett. 50, 682 (1983).
- [3]³R. Numata, R. Ball, and R. L. Dewar, Phys. Plasmas 14, 102312 (2007).
- [4]⁴J. Anderson and B. Hnat, Phys. Plasmas 24, 062301 (2017).
- [5]⁵J. J. van de Wetering and B. Zhu, Phys. Plasmas 33, 073903 (2026).
- [6]⁶C. Ma, B. Zhu, X.-Q. Xu, and W. Wang, Phys. Plasmas 27, 042502 (2020).
- [7]⁷R. Maulik, N. A. Garland, J. W. Burby, X.-Z. Tang, and P. Balaprakash, Phys. Plasmas 27, 072106 (2020).
- [8]⁸B. Zhu, M. Zhao, X.-Q. Xu, A. Gupta, K. Kwon, X. Ma, and D. Eldon, Phys. Plasmas 32, 062508 (2025).
- [9]⁹J. Kates-Harbeck, A. Svyatkovskiy, and W. Tang, Nature 568, 526 (2019).
- [10]¹⁰I. Abramovic, E. P. Alves, and M. Greenwald, J. Plasma Phys. 88, 895880604 (2022).
- [11]¹¹C. Gahr, I.-G. Farcaș, and F. Jenko, Phys. Plasmas 31, 113904 (2024).
- [12]K. Li, Y. Cho, X. Garbet, C. Wan, R. Varennes, K. Lim, V. Grandgirard, and Z. Qu, arXiv preprint (2025), 2509.11576.
- [13]J. Castagna, F. Schiavello, L. Zanisi, and J. Williams, Phys. Plasmas 31, 033902 (2024).
- [14]B. Clavier, D. Zarzoso, D. del Castillo-Negrete, and E. Frénod, Phys. Rev. E 111, L013202 (2025).
- [15]J. Ho, A. Jain, and P. Abbeel, Advances in Neural Information Processing Systems 33, 6840 (2020).
- [16]Y. Lipman, R. T. Q. Chen, H. Ben-Hamu, M. Nickel, and M. Le, in International Conference on Learning Representations (ICLR) (2023) 2210.02747.
- [17]P. Du, M. H. Parikh, X. Fan, X.-Y. Liu, and J.-X. Wang, Nat. Commun. 15, 10416 (2024).
- [18]X. Fan, D. Akhare, and J.-X. Wang, Comput. Methods Appl. Mech. Engrg. 433, 117478 (2025).
- [19]V. Oommen, S. Khodakarami, A. Bora, Z. Wang, and G. E. Karniadakis, arXiv preprint (2025), 2509.08752.
- [20]M. H. Parikh, X. Fan, and J.-X. Wang, J. Fluid Mech. 1029, A32 (2026).
- [21]X. Fan, M. H. Parikh, Y. Liu, X.-Y. Liu, J. Guo, M. Wang, and J.-X. Wang, Physical Review Fluids 11, 084607 (2026).
- [22]B. Zhu, M. Francisquez, and B. N. Rogers, Comput. Phys. Commun. 232, 46 (2018).
- [23]J. Ho and T. Salimans, arXiv preprint arXiv:2207.12598 (2022).arxiv.org/abs/2207.12598
- [24]H. Chung, J. Kim, M. T. Mccann, M. L. Klasky, and J. C. Ye, in International Conference on Learning Representations (ICLR) (2023) 2209.14687.
- [25]M. H. Parikh, Y. Chen, and J.-X. Wang, Journal of Computational Physics 567, 115359 (2026).
- [26]K. Schwarz, Y. Liao, and A. Geiger, Advances in Neural Information Processing Systems 34, 18126 (2021).
- [27]A. Mathews, M. Francisquez, J. W. Hughes, D. R. Hatch, B. Zhu, and B. N. Rogers, Physical Review E 104, 025205 (2021).













