betaFeedback

WorksComputer Science

SF-Flow: Spectral Flow Matching with High Structural Fidelity for Hallucination-Suppressed Scientific Image Generation

Abstract

Scientific image generation focuses on reproducing experimental appearance while following a prescribed spatial layout. A key challenge is acute data sparsity, which requires operating with unpaired collections of materials (real images and prescribed layouts), where no direct supervision is feasible. Work on unpaired translation has shown that it is possible to reproduce the texture and intensity variations of real images, but it is extremely hard to retain the intended phase boundaries in the prescribed locations. This paper tackles this challenge and introduces SF-Flow, a flow-matching model trained only on real material images that imposes spectral constraints during generation, producing images that are high-fidelity and consistent with the prescribed layouts. Because layouts enter only at generation time, the approach extends to layout maps outside the distribution of any available training layouts. We evaluate the method on synchrotron tomography of concrete, lens-coupled laboratory microCT of powders, and industrial XCT of additively manufactured metal. Without instrument-specific modeling, we show that SF-Flow achieves substantially higher template agreement and joint fidelity–structure score than previous methods, including contrastive unpaired translation.

Introduction

Synthetic images with known structure are increasingly important in computational materials science and other scientific domains, where they provide labeled data for quantitative image analysis. Here, access to accurate labels associated to segmented images is key as they determine measurements such as porosity, defect statistics, and phase fractions. These data support training segmentation models [19, 43] and enable algorithm testing and studies of how microstructure affects material properties [17, 20], reducing dependence on costly experiments and broadening the designs that can be examined in silico.

However, obtaining realistic images with reliable labels remains a key challenge. Experimental scans are costly, and manual annotation is time-consuming and error prone, especially where limited resolution makes phase boundaries difficult to locate. In this context, physics-based simulators have been exploited to generate material layouts with known labels, but their images differ from experimental scans in texture, intensity variation, and noise [44]. Experimental images and prescribed layouts therefore form unpaired collections. Thus, to generate realistic scientific images that preserve a prescribed material layout, one has to face the problem of linking a layout to its experimental appearance, without direct supervision.

This is a fundamental problem which has been studied in several directions. First, noting that unpaired translation can give simulated images the texture and intensity variation of real scans, a cycle-consistent generative adversarial network (CycleGAN) encourages content preservation through cycle consistency [41], and constrained contrastive unpaired translation (C-CUT) adapts patchwise contrastive learning [28] to concrete X-ray computed tomography (XCT) [44]. Curating simulations to match experimental feature sizes and densities [32, 44] requires knowing the statistics that segmentation is meant to measure. When these statistics differ, matching the target distribution can favor changes to the layout. Cohen et al. [7] found that changing tumor prevalence in the target set could lead a translator to add or remove tumor-like features in synthetic magnetic resonance (MR) images of the brain. In synchrotron concrete, the same objective can favor larger pores if they are more common in the experimental collection. In that regime, a pore can look realistic while extending beyond its prescribed boundary, as the red overlays in Figure 1 illustrate.

Figure 1. Phase hallucinations on three concrete layouts (rows). Each material map is followed by generated images and disagreement overlays. Colors identify extra predicted pore (red), paste (blue), and main structure (purple) outside their prescribed regions.

However, while these methods preserve image realism they do not capture the prescribed layout precisely. Distributional scores such as FID do not establish image–map correspondence, and structural guidance applied during sampling can degrade texture and intensity statistics. Yet the exact structural layout is essential: material properties such as porosity, connectivity, and transport depend on the precise location of phases and boundaries, so a realistic image with the wrong layout is of little scientific value.

We address this gap with SF-Flow, which trains a flow-matching model [23, 24] on a single data modality, real images, and imposes layout constraints only at generation time. The pretrained model serves as an appearance prior and requires no paired data. Our key technical idea is a spectral constraint in Fourier space: we compare each generated image with an intensity template derived from its material map and bound their difference within a selected low-frequency band. This controls coarse spatial agreement and leaves higher-frequency texture and noise unconstrained. The constraint is enforced by viewing sampling as an optimization process, where, at selected steps, a finite primal–dual solver finds the smallest change to the predicted clean image that satisfies the constraints, and the sampler then resumes integration from the corrected state. To retain fidelity, we add a cohort-level constraint that bounds the maximum mean discrepancy [12] between generated and real Inception features, so each structural correction accounts for its effect on the feature statistics of the generated set.

We demonstrate the ability of SF-Flow to generate realistic images that adhere closely to prescribed layouts, on real examples of synchrotron concrete, lens-coupled laboratory microCT of powder, and industrial XCT of additively manufactured metal. In each case, SF-Flow produces higher Multi-Scale Structure Similarity and lower phase hallucination rates for each key segmentation region of the image that are important for downstream use.

Contributions. We make three contributions: (1) We introduce SF-Flow, a framework for scientific image synthesis from unpaired material maps and experimental scans that trains an unconditional flow learner from unlabeled scans and imposes layout constraints at generation time. (2) We couple a spectral constraint on each image’s layout with an MMD constraint on cohort fidelity, using a primal–dual solver to approximate the joint projection during generation and at the final state. (3) We evaluate image fidelity and layout agreement on synchrotron XCT of concrete, lens-coupled laboratory microCT of powder, and industrial XCT of additively manufactured metal. On concrete, we also evaluate higher-resolution synthesis and SAM adaptation.

Related Work

Synthetic Labeled Data for Scientific Imaging. Researchers train segmentation and reconstruction networks on synthetic image–label pairs when experimental ground truth is unavailable. In XCT of additively manufactured parts, physics-based simulators render CAD models with embedded defect libraries for artifact suppression [42, 43], and GAN-translated simulations support SAM adaptation for multiclass flaw segmentation [32]. Simulated microstructures with degraded reconstructions likewise support foundation-model adaptation on gigapixel tomography [38]. Researchers use comparable pipelines in fluorescence microscopy [8] and randomized-contrast label-map synthesis in medical imaging [2]. These approaches supply labels, but retain simulation’s appearance gap or translate between collections with similar content statistics.

Unpaired Translation and Scientific Synthesis. Unpaired translators address this appearance gap by inferring correspondence from source images, whereas semantic synthesis uses layouts to guide object placement and shape in natural images [27]. CycleGAN uses cycle consistency [41] and CUT matches corresponding patch features [28]; other objectives preserve geometry under spatial transformations [9] or semantic consistency across domains with differing content [15]. Yet Cohen et al. [7] found that overall anatomy can survive translation while individual features appear or disappear. Material generators face this distinction: adversarial models reproduce pore statistics [11, 26] and design microstructures [36], while diffusion models reconstruct morphologies [20], but matching statistics does not establish image–map correspondence. C-CUT adds a label channel and a label-consistency loss to encourage microstructure preservation [44]. Even so, a pore can match its prescribed area while extending into paste, giving a segmenter incorrect paste labels for pore pixels. FID [13] compares collections and cannot detect this per-pair error.

Flow Matching and Constrained Sampling. Researchers can instead impose requirements while sampling from diffusion [14, 30, 31] or flow-matching [23, 24] priors. In inverse problems, observations guide sampling trajectories [6, 40] or constrain known pixels and measured components [16, 25, 34]; other methods optimize initial noise [1] or incorporate projection into training [5]. Sampling-time methods evaluate constraints on decoded images [37] or express them as chance constraints on intermediate states [22]. Projected Diffusion Models (PDM) project the current sample after each Langevin update [4], whereas Physics-Constrained Flow Matching (PCFM) corrects a predicted clean endpoint and transfers the correction to the current flow state [33]. Structural correction alone need not match the texture and noise of real XCT cohorts.

We address this distinction by pairing per-image spectral guidance with cohort-level MMD during sampling. Earlier generative models use MMD for distribution matching during training [12, 21], and Kernel Inception Distance uses it for evaluation [3]. In SF-Flow, the spectral bound limits low-frequency differences from each map template, while a shared MMD bound compares real features with those of the active batch and completed outputs.

Problem Setting and Preliminaries

Unpaired Datasets

We consider XCT generation from separate collections of material maps and experimental images. Let Ω\Omega be a pixel grid with n=∣Ω∣n = |\Omega|. A phase map m:Ω→{1,…,K}m : \Omega\to\{1, \ldots, K\} assigns one material class to each pixel. Our main case study, synchrotron tomography of concrete, uses K=3K = 3 classes: pore, paste, and main structure. The map collection Dgeom={mi}i=1Ng\mathcal{D}_{\mathrm{geom}} = \{m_i\}_{i=1}^{N_g} specifies the requested material layouts. The image collection Dxct={rj}j=1Nxct\mathcal{D}_{\mathrm{xct}} = \{r_j\}_{j=1}^{N_{\mathrm{xct}}} contains unannotated images from the experimental distribution pxctp_{\mathrm{xct}}. The collections are unpaired: no real image rjr_j is assumed to match a particular map mim_i. Nor do we assume that the maps share the feature-size, density, or spatial statistics of the real images: simulated microstructures and real specimens may differ in content as well as appearance.

We scale XCT intensities to [−1,1][-1,1] before training and sampling; rjr_j and xx denote images in this model-space range. A simulated grayscale image accompanies each material map and is reserved for evaluation of SF-Flow. The velocity model learns from real images alone. Material maps enter through sampling-time constraints, while the trained model remains fixed.

The goal is a pair in which the image is indistinguishable from experimental data and the map is a correct segmentation of the image. Writing SS for an ideal segmenter, we seek generated cohorts that follow the experimental distribution and satisfy

S(xi)=mifor every generated image xi.(1)S(x_i) = m_i \quad\text{for every generated image } x_i. \tag*{(1)}

Neither requirement can be evaluated directly. We replace the distributional requirement with a cohort-level feature constraint against and Eq. (1) with a per-image spectral constraint against an intensity template derived from each map (Sec. 4). The spectral constraint controls agreement only above a spatial scale set by its cutoff, so we also measure label agreement directly (Sec. 5).

Flow Matching for Material Generation

We train an unconditional flow model on real XCT images. For each example, we independently draw Gaussian noise x0∼N(0,I)x_0 \sim\mathcal{N}(0,I), a real image x1∼pxctx_1 \sim p_{\mathrm{xct}}, and a time t∼U[0,1)t \sim\mathcal{U}[0,1). A U-Net with time-conditioned residual blocks and encoder–decoder skip connections predicts the velocity vθ(xt,t)v_\theta(x_t,t) along the straight path from x0x_0 to x1x_1. We fit the velocity field with the flow-matching loss

xt=(1−t)x0+tx1,LFM=E∥vθ(xt,t)−(x1−x0)∥22.(2)x_t=(1-t)x_0+tx_1,\quad\mathcal{L}_{\mathrm{FM}}=\mathbb{E}\left\lVert v_\theta(x_t,t)-(x_1-x_0)\right\rVert_2^2. \tag*{(2)}

At sampling time, we draw x0x_0 from the same Gaussian source and integrate dxtdt=vθ(xt,t)\frac{\mathrm{d}x_t}{\mathrm{d}t}=v_\theta(x_t,t) from t=0t=0 to t=1t=1. SF-Flow keeps the learned velocity field fixed and guides the trajectory toward the prescribed layout by projecting predicted endpoints at selected steps. A final projection acts on the integrated image (§ 4).

Methodology

An unconditional flow provides experimental appearance, but does not associate samples with a material map. A structural correction can establish this correspondence while changing texture and noise. SF-Flow addresses both in one projection: a spectral bound controls layout agreement over selected frequencies, and an MMD bound limits discrepancy between generated and real image features.

The sampler evaluates these constraints on predicted clean images (Figure 2). At selected steps, it approximates their minimum-displacement projection and transfers the correction to the current flow state. Integration then resumes from the corrected state. A final joint projection at t=1t=1 acts on the integrated images before output encoding.

Figure 2. Overview of SF-Flow. A real-image flow prior predicts clean endpoints during sampling. Joint projection seeks the smallest correction satisfying per-image low-frequency template agreement (green) and cohort MMD fidelity (orange), using active predictions, completed outputs, and real references. Corrections update the flow state before integration resumes. A final joint projection at t=1t = 1 precedes encoding, with no further ODE steps.

Projected Flow Matching

The constraints describe clean images, so we apply them to an endpoint estimate derived from the current state and velocity. The straight-path formulation in Eq. (2) gives the local estimates

x^0=xt−tvθ(xt,t),x^1=xt+(1−t)vθ(xt,t).(3)\widehat{x}_0=x_t-tv_\theta(x_t,t),\quad\widehat{x}_1=x_t+(1-t)v_\theta(x_t,t). \tag*{(3)}

The pair (x^0,x^1)(\widehat{x}_0,\widehat{x}_1) represents xtx_t on a local straight line. We assess structure and fidelity at the predicted endpoint x^1\widehat{x}_1.

For a batch of BB images, write the endpoint predictions as x^1=(x^1,1,…,x^1,B)\widehat{x}_1=(\widehat{x}_{1,1},\ldots,\widehat{x}_{1,B}). Let Ct⊆XB\mathcal{C}_t\subseteq\mathcal{X}_B, where XB=[−1,1]B×n\mathcal{X}_B=[-1,1]^{B\times n}, be the set satisfying the material-map and cohort requirements at time tt. The projection seeks the smallest change that places the batch in this set:

xproj=arg⁡min⁡x∈Ct∥x−x^1∥F2.(4)x_{\mathrm{proj}}=\underset{x\in\mathcal{C}_t}{\arg\min}\left\lVert x-\widehat{x}_1\right\rVert_F^2. \tag*{(4)}

The Frobenius norm ∥x−x^1∥F2=∑i=1B∥xi−x^1,i∥22\left\lVert x-\widehat{x}_1\right\rVert_F^2=\sum_{i=1}^{B}\left\lVert x_i-\widehat{x}_{1,i}\right\rVert_2^2 sums squared intensity changes over the batch’s pixels. We transfer this correction to the trajectory by retaining the source estimates x^0\widehat{x}_0 and replacing x^1\widehat{x}_1 with xprojx_{\mathrm{proj}}:

xt+=(1−t)x^0+txproj=xt+t(xproj−x^1).(5)x_t^+=(1-t)\widehat{x}_0+tx_{\mathrm{proj}}=x_t+t(x_{\mathrm{proj}}-\widehat{x}_1). \tag*{(5)}

The weight tt scales the endpoint displacement at the current flow time. We reevaluate the velocity at xt+x_t^+ and continue Heun integration from this corrected state.

Even when the corrected endpoint satisfies both constraints, the remaining Heun steps can produce a final batch that violates them. We apply the joint projection once more at t=1t=1, when the endpoint prediction equals the integrated batch x1x_1. The final spectral budget and the cohort MMD requirement define the feasible set C1\mathcal{C}_1. We seek the closest batch in that set, xfinal=arg⁡min⁡x∈C1∥x−x1∥F2x_{\mathrm{final}}=\arg\min_{x\in\mathcal{C}_1}\left\lVert x-x_1\right\rVert_F^2. The update in Eq. (5) then gives x1+=xfinalx_1^+=x_{\mathrm{final}}. We use this corrected batch as the continuous output without another ODE step.

Spectral Structure Constraint

A phase map specifies material classes, while the flow generates intensities. We connect these representations through an intensity template. Let μk∈[0,1]\mu_k\in[0,1] be the mean experimental intensity of class kk. The template for map mm assigns this mean to each region in the model’s [−1,1][-1,1] range:

qm(p)=2μk−1if m(p)=k.(6)q_m(p)=2\mu_k-1\quad\text{if }m(p)=k. \tag*{(6)}

The piecewise-constant template qmq_m describes the requested layout without texture or imaging noise. Pixelwise matching would suppress these variations, so we compare the image and template within a selected frequency band.

Let F\mathcal{F} denote the unitary discrete Fourier transform, and let ρ(ω)\rho(\omega) be the radial frequency at coordinate ω\omega, measured in cycles per pixel. A cosine low-pass filter selects the band with cutoff cc and transition width ww:

Hc,w(ρ)={1,ρ≤c,12(1+cos⁡(π(ρ−c)/w)),c<ρ<c+w,0,ρ≥c+w.(7)H_{c,w}(\rho)= \begin{cases} 1, & \rho\le c,\\ \frac{1}{2}\left(1+\cos\left(\pi(\rho-c)/w\right)\right), & c<\rho<c+w,\\ 0, & \rho\ge c+w. \end{cases} \tag*{(7)}

For a candidate endpoint z∈[−1,1]nz\in[-1,1]^n, the structural residual relative to qmq_m is

Rc,w(z;qm)=1n∥Hc,w⊙[F(z)−F(qm)]∥2.(8)R_{c,w}(z;q_m)=\frac{1}{\sqrt{n}}\left\lVert H_{c,w}\odot\left[\mathcal{F}(z)-\mathcal{F}(q_m)\right]\right\rVert_2. \tag*{(8)}

The residual Rc,wR_{c,w} is the root-mean-square filtered difference. Frequencies below cc receive full weight; the weights taper between cc and c+wc+w and vanish above c+wc+w. We require each active image to satisfy

Rc,w(zi;qmi)≤ϵtfor every active image i,(9)R_{c,w}(z_i;q_{m_i})\le\epsilon_t\quad\text{for every active image }i, \tag*{(9)}

The budget ϵt\epsilon_t decreases linearly across intermediate projection events, tightening structural agreement as sampling progresses. The terminal projection uses ϵ1=ϵfinal\epsilon_1=\epsilon_{\mathrm{final}}. Frequencies above c+wc+w remain unconstrained by this bound; the fidelity constraint controls appearance through image features. A structure LL pixels wide concentrates its energy near 1/(2L)1/(2L) cycles per pixel, so with default c=0.06c=0.06 and w=0.01w=0.01 the bound controls features wider than about seven pixels. Smaller features, such as small pores and thin paste ligaments, are placed by the prior rather than the constraint; our boundary variants (§ 5.1) target this regime.

MMD Fidelity Constraint

MMD compares the generated cohort with real reference images in the feature space of a frozen Inception network, ϕ(x)∈Rd\phi(x) \in\mathbb{R}^{d}. These features can reflect pore density as well as texture. If the prescribed maps contain more pores than the real images, reducing MMD can favor a lower pore density in the generated cohort. The per-image spectral bound limits how far each candidate can depart from its map at the selected frequencies. A cohort that meets those structural bounds can therefore still exceed its MMD budget.

We select a fixed reference set R⊆Dxct\mathcal{R} \subseteq\mathcal{D}_{\mathrm{xct}} containing NrN_r real images and index them within this set as R={rj}j=1Nr\mathcal{R} = \{r_j\}_{j=1}^{N_r}. Let G\mathcal{G} denote a generated cohort. We compare their features with the cubic kernel k(a,b)=(1+a⊤b/d)3k(a,b) = (1 + a^\top b/d)^3. The biased empirical MMD estimator is

DMMD2(G,R)=1∣G∣2∑g,g′∈Gk(ϕ(g),ϕ(g′))+1Nr2∑j,j′k(ϕ(rj),ϕ(rj′))−2∣G∣Nr∑g∈G∑jk(ϕ(g),ϕ(rj)).(10)\begin{aligned} D_{\mathrm{MMD}}^2(\mathcal{G},\mathcal{R}) ={}& \frac{1}{|\mathcal{G}|^2}\sum_{g,g'\in\mathcal{G}} k(\phi(g),\phi(g')) \\ &+ \frac{1}{N_r^2}\sum_{j,j'} k(\phi(r_j),\phi(r_{j'})) \\ &- \frac{2}{|\mathcal{G}|N_r}\sum_{g\in\mathcal{G}}\sum_j k(\phi(g),\phi(r_j)). \tag*{(10)} \end{aligned}

The within-set sums retain diagonal self-similarity terms. This biased estimator is nonnegative and defined for a one-image prefix. The unbiased KID estimator instead omits these terms, requires at least two samples per set, and can be negative for finite samples [3, 12]. We use the biased form to apply one nonnegative statistic throughout generation.

During sampling, the current batch x=(x1,…,xB)\mathbf{x} = (x_1,\ldots,x_B) extends a growing prefix of generated images. The prefix has size NN: it contains the BB candidates and N−BN-B completed outputs, denoted XN−B={xˉℓ}ℓ=1N−B\mathcal{X}_{N-B} = \{\bar{x}_{\ell}\}_{\ell=1}^{N-B}. Together they form GN(x)=XN−B∪{xi}i=1B\mathcal{G}_N(\mathbf{x}) = \mathcal{X}_{N-B} \cup\{x_i\}_{i=1}^{B}. We cache the features of completed images and detach them from the gradient graph. Only the current batch changes under the shared constraint

DMMD2(GN(x),R)≤τN.(11)D_{\mathrm{MMD}}^2(\mathcal{G}_N(\mathbf{x}),\mathcal{R}) \le\tau_N. \tag*{(11)}

MMD depends on prefix size, so we calibrate a threshold τN\tau_N for each NN. We generate 500 unconditional images with the same checkpoint and batch size, permute their features 25 times, and compute biased MMD at every prefix. We set τN\tau_N to γ\gamma times the 75th percentile at size NN.

Joint Projection Solver

The spectral bound applies to each active image, while the MMD bound couples the batch to the full prefix. Their intersection defines CtC_t. Substituting these requirements into Eq. (4) gives

xproj=argmin⁡x∈XB12σd2Bn∥x−x^1∥F2subject toRc,w(xi;qmi)≤ϵt,i=1,…,B,DMMD2(GN(x),R)≤τN.(12)\begin{aligned} \mathbf{x}_{\mathrm{proj}} = \underset{\mathbf{x}\in\mathcal{X}_B}{\operatorname{argmin}}\quad&\frac{1}{2\sigma_d^2 Bn}\left\|\mathbf{x}-\widehat{\mathbf{x}}_1\right\|_F^2 \\ \text{subject to}\quad&R_{c,w}(x_i;q_{m_i}) \le\epsilon_t,\quad i=1,\ldots,B,\\ &D_{\mathrm{MMD}}^2(\mathcal{G}_N(\mathbf{x}),\mathcal{R}) \le\tau_N. \tag*{(12)} \end{aligned}

The factor BnBn normalizes the displacement in Eq. (4) to a per-pixel average. We use σd=0.1\sigma_d = 0.1 to set its characteristic scale in model space. This positive rescaling preserves the exact minimizer but affects the updates of a finite solver.

We approximate Eq. (12) with alternating primal and dual updates. After budget normalization, Adam updates the image batch to decrease the Lagrangian. Projected gradient ascent updates the nonnegative constraint multipliers. The cached features remain fixed during updates.

A verifier tests both constraints on every candidate with tolerance η=10−4\eta= 10^{-4}. For positive budgets, a candidate passes when Rc,w2/ϵt2−1≤ηR_{c,w}^2/\epsilon_t^2 - 1 \le\eta for every image and DMMD2/τN−1≤ηD_{\mathrm{MMD}}^2/\tau_N - 1 \le\eta for the cohort. The solver retains the passing candidate with the smallest displacement. If none passes, it returns the least-violating candidate and records a failure. These checks assess feasibility; the finite solver is not guaranteed to find a feasible point or a global minimum.

Intermediate solves use the predicted endpoint as the displacement reference, then return to flow integration through Eq. (5). The terminal solve instead uses the integrated batch x1\mathbf{x}_1 and the budget ϵfinal\epsilon_{\mathrm{final}}. The verifier checks both constraints again after image quantization.

Experiments

We evaluate image fidelity and agreement with prescribed layouts across three X-ray tomography regimes. Synchrotron tomography of concrete uses a quasi-monochromatic parallel beam and a lens-coupled scintillator, so its dominant artifacts are rings and phase-contrast edges. Laboratory microCT of powders uses a polychromatic source with a lens-coupled scintillator and optical magnification, adding beam hardening and photon-limited noise. Industrial XCT of additively manufactured metal uses a high-energy polychromatic cone beam and a flat-panel detector, where scatter, beam hardening, and streaking dominate. In all three, the simulated maps and real scans are unpaired and differ in feature size and density.

The concrete training set contains 72,230 real crops at 256 × 256, 16,051 at 512 × 512, and 3,511 at 1024 × 1024. At 256 × 256, the metal and powder models train on 13,859 and 7,748 real crops, respectively. We reserve 5% of the real crops in each dataset for validation. At each concrete resolution and modality, we evaluate generation on 500 prescribed maps. We also test whether generated concrete images paired with these labels support SAM adaptation.

Synchrotron Concrete

Fidelity and structure metrics. We measure cohort fidelity with Fréchet Inception Distance (FID) [13] on ImageNet Inception-v3 features and per-image structural agreement with multiscale structural similarity (MS-SSIM) [35] against the prescribed map’s unsmoothed class-mean template. Because each phase has one template intensity, suppressed texture can raise MS-SSIM without improving boundaries. We combine the metrics in the normalized hypervolume score

HR=(1−FIDR)+×MS-SSIM,(13)H_R = \left(1 - \frac{\mathrm{FID}}{R}\right)_{+} \times\mathrm{MS\text{-}SSIM}, \tag*{(13)}

where (a)+=max⁡{a,0}(a)_{+} = \max\{a, 0\} and R=172.862R = 172.862 is the FID between real and simulated concrete crops at 256 × 256. We report both components because rankings depend on RR.

Phase hallucination. We assess phase placement by smoothing each saved concrete image with a Gaussian filter (σ=2\sigma= 2 pixels) and assigning pixels to the phase with the closest calibrated mean intensity. For phase kk, we report (Ek/Nk)×100%(E_k/N_k) \times100\%: NkN_k counts prescribed phase-kk pixels, and EkE_k counts those assigned another phase. A pore predicted in paste counts toward the paste rate. A prescribed pore classified as paste counts toward the pore rate. We include all region interiors and boundaries (Table 1 and Table 2).

MethodHR↑H_R \uparrowFID↓\downarrowMS-SSIM↑\uparrowPorePasteMain struct.
SF-Flow0.784214.5880.85656.104.752.33
SF-Flow + soft boundary0.833419.2750.937911.332.591.88
SF-Flow + hard boundary0.532626.0280.627015.9514.017.24
Flow Matching [24]–9.291––––
Spectral-only [10]0.509771.5780.86996.214.492.20
MMD-only [12]0.54769.3000.578895.0560.2444.72
C-CUT [44]0.716512.3140.77147.9114.2234.49
C-CUT + hard boundary0.0000206.7830.66802.1584.0526.30
C-CUT + soft boundary0.709912.3880.764710.3414.5438.38
UNSB [18]0.699810.5360.74525.7617.7321.88
Diffusion Translation [39]0.509268.3540.84232.268.139.11
PDM [4]0.596958.1080.89925.566.082.44
PCFM [33]0.636644.2160.855310.447.473.92

Table 1. Synchrotron concrete synthesis on 500 256 × 256 maps. Metrics measure cohort fidelity (FID), template agreement (MS-SSIM), and their combined score (HRH_R, Eq. (13)). Phase hallucination is the per-phase percentage of prescribed pixels misclassified by intensity-based segmentation. Flow Matching samples it without guidance, Spectral-only retains the per-image layout constraint, and MMD-only retains the cohort feature constraint. Both single-constraint runs use SF-Flow batch size B=8B = 8 and match the corresponding constraint setting (Sec. A.2). Diffusion Translation is our XCT adaptation of InST [39] style-transfer approach.

Method512 × 512 HR↑H_R \uparrow512 × 512 FID↓\downarrow512 × 512 MS-SSIM↑\uparrow512 × 512 Pore512 × 512 Paste512 × 512 Main struct.1024 × 1024 HR↑H_R \uparrow1024 × 1024 FID↓\downarrow1024 × 1024 MS-SSIM↑\uparrow1024 × 1024 Pore1024 × 1024 Paste1024 × 1024 Main struct.
SF-Flow0.642135.4300.80778.746.883.810.359189.8350.74767.306.295.52
SF-Flow + soft boundary0.737437.8220.943912.792.191.910.464487.7030.942710.612.042.09
SF-Flow + hard boundary0.438352.9170.631614.0113.786.290.2632101.2440.635411.6213.155.85
Flow Matching [24]–23.876–––––62.610––––
Spectral-only [10]0.2832112.4230.81018.816.863.750.0000188.5960.74627.136.365.61
MMD-only [12]0.487125.9500.573296.0958.3947.570.359262.8610.564596.3952.9150.79
C-CUT [44]0.624026.3090.736026.6018.8227.030.345193.4790.751421.9215.4238.27
C-CUT + hard boundary0.0000287.9070.610135.1881.2412.570.0000304.7060.764722.5285.7549.63
C-CUT + soft boundary0.601828.6530.721421.6318.1430.700.344692.7940.743913.6013.0853.96

Table 2. Higher-resolution concrete synthesis on 500 maps per resolution (499 readable C-CUT pairs at 1024 × 1024). Metrics measure cohort fidelity (FID), template agreement (MS-SSIM), their combined score (HRH_R), and per-phase misclassification. Flow Matching is unguided, Spectral-only constrains per-image layout, and MMD-only constrains the cohort’s feature distribution. Soft-boundary SF-Flow reduces paste and main-structure errors but increases pore errors. At 1024 × 1024, SF-Flow and C-CUT use different FID references (Sec. A.3).

Fidelity and structural agreement across baselines. Constrained contrastive unpaired translation (C-CUT) [44] and the Unpaired Neural Schrödinger Bridge (UNSB) [18] achieve lower FID than SF-Flow on concrete, but both have lower template MS-SSIM (Table 1). Main-structure error is 34.49% for C-CUT and 2.33% for SF-Flow. Relative to the unpaired-translation baselines, SF-Flow substantially reduces hallucination in paste and main structure, and its pore error is lower than C-CUT’s and comparable to UNSB’s. The pore advantage over C-CUT widens at higher resolution (Table 2). Methods with lower pore error either stay close to the simulated input or give up fidelity. Projected Diffusion Models (PDM) [4] achieve higher template MS-SSIM than SF-Flow with spectral guidance, and Physics Constrained Flow Matching (PCFM) [33] with an inferred endpoint nearly matches SF-Flow. Both have higher FID (58.108 and 44.216, respectively, versus 14.588). Our Diffusion Translation baseline draws on Zhang et al. [39]. For each modality, we train a single denoiser on simulated images with a material mask and a synthetic-domain label and on experimental images with only an experimental-domain label. At inference, we add sampled Gaussian noise to the simulated image x0x_0 and denoise it under the experimental-domain label.

The single-constraint results expose the tradeoff addressed by joint guidance (Figure 3). MMD-only sampling gives a FID close to the unconditional sampling; spectral-only sampling raises MS-SSIM to 0.8699 but FID to 71.578. Joint guidance retains MS-SSIM 0.8565 with FID 14.588, yielding HR=0.7842H_R = 0.7842. The spectral constraint supplies per-image layout information, while MMD limits cohort feature discrepancy.

Figure 3. Synchrotron concrete samples for three layouts (rows), using Table 1 settings. Map colors denote pore (dark blue), paste (gray-blue), and main structure (yellow); images share the grayscale range [0, 255]. Spectral guidance promotes layout agreement, while MMD controls cohort appearance. MMD-only and unconditional sampling impose no per-image layout constraint.

Several SF-Flow settings improve both metrics over evaluated C-CUT checkpoints (Figure 4). We selected settings on the evaluation cohort with unequal search budgets. The flow comparison uses one seed (Secs. A, A.2, and B.1).

Figure 4. Fidelity–structure tradeoffs on 256 × 256 concrete. Better settings have lower FID and higher template MS-SSIM (upper left). Lines connect each method’s nondominated settings; faint points show other configurations. Frontiers use all points before cropping at FID 30. Search budgets differ and flow uses one seed.

Hard and soft boundary constraints. We test hard and soft correction with C-CUT and SF-Flow. Hard correction copies simulated-image pixels within a label-derived boundary band, preserving them exactly but potentially retaining synthetic texture. Soft correction penalizes differences between predicted segmentation edges and label boundaries through λboundary\lambda_{\mathrm{boundary}}, allowing texture and intensity changes. SF-Flow predicts these edges with a differentiable Gaussian intensity classifier. Its boundary variants use ϵfinal=0.02\epsilon_{\mathrm{final}} = 0.02, versus 0.01 for the standard configuration; Sec. A.2 gives the settings and matched control. Compared with the standard SF-Flow, soft boundary guidance raises MS-SSIM from 0.8565 to 0.9379, leading to the gain of HRH_R from 0.7842 to 0.8334 even as FID worsens (14.588 vs. 19.275). The variant reduces the paste and main-structure errors, but almost doubles the pore error from 6.10% to 11.33%. Hard guidance preserves boundary-band pixels but gives lower template agreement and higher FID.

Higher-resolution XCT microstructure. At 512×512512 \times512, SF-Flow again trades higher FID for stronger template agreement than C-CUT (35.430 vs. 26.309 and 0.8077 vs. 0.7360; Table 2). At 1024×10241024 \times1024, SF-Flow reaches FID 89.835 and MS-SSIM 0.7476. At both resolutions, soft boundary guidance reduces paste and main-structure hallucination but increases pore hallucination relative to standard SF-Flow. Thus stronger template agreement need not improve pore labels, a distinction relevant to porosity and defect measurements. Figure 5 shows both resolutions; Sec. A.3 details the cohorts.

Figure 5. Higher-resolution synchrotron concrete synthesis for the methods in Table 2. Each panel shows three examples, comparing SF-Flow, its single-constraint and boundary variants, and C-CUT with its boundary variants. (a) At 512×512512 \times512, methods share the prescribed material map in each row. (b) At 1024×10241024 \times1024, SF-Flow and C-CUT use different crop sets; their corresponding maps are shown in the “Flow label” and “C-CUT label” columns. The final two columns show unconditional samples and unpaired real references for comparison of texture and imaging appearance, without correspondence to the prescribed layouts.

Ablation Studies

The single-constraint sweeps confirm that tighter spectral budgets strengthen template agreement at an appearance cost: MS-SSIM and FID both increase (Table A1). The MMD threshold’s effect on FID depends on batch size and is not always monotonic, so tighter cohort constraints alone need not improve this separate fidelity metric.

BBγ\gammaHR↑H_R \uparrowFID↓\downarrowMS-SSIM↑\uparrowPorePasteMain struct.
10.500.55179.1500.582597.2160.5942.59
10.750.55209.1760.583097.2160.6142.57
11.000.55149.3540.583097.2160.6242.57
11.250.55099.5100.583097.2160.6142.57
20.500.54718.9030.576896.6358.9344.72
20.750.54659.2620.577496.6258.9444.70
21.000.54549.6670.577796.6258.9444.69
21.250.54519.7840.577896.6258.9544.68
40.500.54578.8040.575094.5559.7844.93
40.750.54468.9690.574495.0559.1544.82
41.000.54489.2530.575695.0559.1644.78
41.250.54559.5210.577395.0859.5344.79
80.500.52698.9920.555895.4058.1445.68
80.750.53979.4110.570896.1859.3445.32
81.000.54399.4310.575396.0758.9744.06
81.250.54769.3000.578895.0560.2444.72
160.500.50889.7140.539196.5457.6745.74
160.750.52609.3180.556096.5658.0545.41
161.000.52949.5300.560396.5758.0745.38
161.250.53219.9390.564696.6058.1045.28

Table A1. Single-constraint sweeps on 500 synchrotron concrete maps at 256 × 256. (a) MMD-only varies the threshold multiplier γ\gamma; (b) spectral-only varies the final residual budget ϵfinal\epsilon_{\mathrm{final}}. Smaller values tighten the corresponding constraint, and BB is the sampling batch size. FID measures cohort fidelity, MS-SSIM measures agreement with the unsmoothed template, and HRH_R combines both; arrows indicate the preferred direction. Phase hallucination reports the percentage of prescribed pixels assigned another phase. Tighter spectral budgets improve template agreement but raise FID, while the effect of the MMD threshold on FID depends on batch size. (a) MMD-only: threshold factor and batch size. Phase hallucination (%, ↓\downarrow). (b) Spectral-only: residual budget and batch size. Phase hallucination (%, ↓\downarrow).

When SF-Flow corrects throughout sampling, terminal projection changes FID only from 13.989 to 13.993. Ending intermediate correction early increases the terminal solve’s fidelity cost, indicating that continued guidance reduces reliance on a costly terminal correction. Table A2 also examines batch size, budgets, and target smoothing.

BBϵfinal\epsilon_{\mathrm{final}}γ\gammaσ\sigmatendt_{\mathrm{end}}TerminalHR↑H_R \uparrowFID↓\downarrowMS-SSIM↑\uparrowPorePasteMain struct.
80.021.2511.00No0.765713.9890.83318.957.033.67
80.021.2511.00Yes0.765713.9930.83318.957.033.66
80.021.2510.80No0.757912.9990.81957.647.954.18
80.021.2510.80Yes0.365396.8560.83096.906.703.27
80.021.2510.65No0.706914.2680.77057.0410.185.61
80.021.2510.65Yes0.0000240.0460.79976.047.263.36
10.021.2511.00Yes0.750117.0350.83217.267.853.48
20.021.2511.00Yes0.763915.0560.83687.827.333.45
40.021.2511.00Yes0.769614.1250.83818.436.963.52
160.021.2511.00Yes0.739513.9400.80439.767.534.31
80.011.2511.00Yes0.784214.5880.85656.104.752.33
80.031.2511.00Yes0.739813.3880.801913.1911.616.46
80.021.2501.00Yes0.763514.0610.83128.706.953.69
80.021.2521.00Yes0.759914.3840.82889.837.423.91
80.021.2531.00Yes0.756514.1810.824111.497.824.28
40.020.2511.00Yes0.756711.3240.80978.337.664.01
40.020.511.00Yes0.767312.3740.82648.367.243.65
40.02111.00Yes0.771213.6230.83728.467.053.46
40.030.2511.00Yes0.733510.9290.783012.5212.086.97
40.030.511.00Yes0.744111.8480.789012.7312.046.64
40.03111.00Yes0.747213.2410.809212.8211.706.36
40.010.511.00Yes0.787912.7370.85065.824.892.34
40.01111.00Yes0.788214.2900.85925.844.712.22
40.0150.511.00Yes0.777512.6820.83916.935.772.87
40.015111.00Yes0.781113.8880.84936.905.572.70
80.010.511.00Yes0.768612.7550.82985.985.392.82
80.01111.00Yes0.783314.2600.85376.044.792.38
80.0150.511.00Yes0.760112.5780.81977.076.193.33
80.015111.00Yes0.773613.8410.84097.215.722.93

Table A2. SF-Flow sampling ablations on 500 synchrotron concrete maps at 256 × 256. Columns specify batch size BB, final spectral budget ϵfinal\epsilon_{\mathrm{final}}, MMD threshold multiplier γ\gamma, template smoothing width σ\sigma in pixels, and the final time tendt_{\mathrm{end}} of intermediate guidance. “Terminal” indicates a joint projection at t=1t = 1 before image encoding. Metrics assess cohort fidelity (FID), template agreement (MS-SSIM), their combined score (HRH_R), and phase misclassification percentages. Ending intermediate guidance early substantially increases the FID cost of terminal projection. Bold identifies the configuration used in Table 1, selected before the tighter-budget follow-ups.

Comparison Across Imaging Regimes

We compare SF-Flow, C-CUT, UNSB, Diffusion Translation, PDM, and PCFM across synchrotron concrete, laboratory microCT powder, and industrial XCT metal AM using 500 maps per dataset at 256×256256 \times256 (Table 3). We use the concrete settings from Table 1; Sec. A.3 describes metal and powder.

MethodXCT Concrete HR↑H_R \uparrowXCT Concrete FID↓\downarrowXCT Concrete MS-SSIM↑\uparrowXCT Metal AM HR↑H_R \uparrowXCT Metal AM FID↓\downarrowXCT Metal AM MS-SSIM↑\uparrowMicroCT Powder HR↑H_R \uparrowMicroCT Powder FID↓\downarrowMicroCT Powder MS-SSIM↑\uparrow
SF-Flow0.784214.5880.85650.823016.8600.91200.860010.8070.9174
SF-Flow + soft boundary0.833419.2750.93790.827617.1620.91890.872911.5960.9356
SF-Flow + hard boundary0.532626.0280.62700.711921.6350.81380.852611.2630.9120
Flow Matching [24]–9.291––9.957––15.421–
C-CUT [44]0.716512.3140.77140.759711.2890.81270.84099.7700.8913
C-CUT + hard boundary0.0000206.7830.66800.0000292.5060.66170.0000243.8110.8619
C-CUT + soft boundary0.709912.3880.76470.77339.8290.82000.841110.0770.8932
UNSB [18]0.699810.5360.74520.802411.8170.86130.84029.5950.8896
Diffusion Translation [39]0.509268.3540.84230.725635.3010.91180.474184.5500.9279
PDM [4]0.596958.1080.89920.713145.0290.96430.742536.0820.9384
PCFM [33]0.636644.2160.85530.705946.6980.96710.583466.0250.9439

Table 3. Synchrotron concrete, industrial XCT metal AM, and laboratory microCT powder synthesis on 500 prescribed 256 × 256 maps per dataset. Flow Matching is the unguided SF-Flow ablation. SF-Flow achieves higher template MS-SSIM and joint score HRH_R than all C-CUT variants, while standard or soft-boundary C-CUT retains lower FID. HRH_R uses the fixed reference R=172.862R = 172.862 and is compared within datasets.

SF-Flow achieves higher template MS-SSIM and HRH_R than every C-CUT variant across all three regimes, extending the layout advantage across different source and detector physics (Figure 6). C-CUT retains lower FID: standard C-CUT is best among its variants on concrete and powder, and soft-boundary C-CUT on metal. On powder, SF-Flow raises MS-SSIM from 0.8913 to 0.9174 with FID increasing from 9.770 to 10.807.

Qualitative comparison across imaging regimes for XCT Concrete, XCT Metal AM, and MicroCT Powder

Figure 6. Qualitative comparison across the imaging regimes in Table 3: synchrotron concrete (top), industrial XCT metal AM (middle), and laboratory microCT powder (bottom). Each group shows three prescribed 256×256256 \times256 material maps with outputs from SF-Flow, C-CUT, their hard- and soft-boundary variants, and Diffusion Translation. Comparing each output with the leftmost map reveals changes in phase placement and boundaries, while the final two columns provide unconditional samples and unpaired real references for assessing appearance. A common grayscale window is used within each dataset.

SAM Segmentation

We fine-tuned the SAM2.1 Large mask decoder [19, 29] on 400 generated or simulated XCT images with identical labels and training settings (Sec. A.4). On 94 generated images from held-out slices of the same volume, identical prompts gave the highest mean IoU and Dice after adaptation on generated pairs (0.7506 and 0.8435), followed by simulated pairs (0.7060 and 0.7983) and pretrained SAM2.1 (0.6284 and 0.7295). This supports their use for adaptation within the generated-image domain; transfer to independent real specimens remains untested.

Discussion and Limitations

Terminal projection. When intermediate guidance stopped at t=0.80t = 0.80, the terminal projection raised FID (Table A2). Every corrected batch passed its MMD check with earlier uncorrected outputs in the cache, yet we saved cohort exceeded the bound. The paired study did not test online cache updates using the saved images (Sec. B.2).

Content hallucination and the fidelity constraint. In C-CUT, a change in phase content can improve the adversarial match to the target collection. In synchrotron concrete, C-CUT achieves a lower FID than SF-Flow, but a higher fraction of the prescribed main-structure misclassified as pore or paste (Table 1). SF-Flow checks the spectral bound in low-frequency agreement with each map and the MMD bound in the discrepancy in the features of the cohort separately. The joint solver does not give bound priority, and finite optimization can also leave a residual. The separate checks let us report which requirement was missed.

Structural agreement and segmentation. The spectral bound constrains agreement over the selected low frequencies. A small pore or thin paste ligament can shift even when the image meets the bound (Sec. 4.2). The phase hallucination rates measure map disagreement through an intensity classifier. Texture changes can alter its assignments even when a phase boundary stays in place. The SAM study evaluated segmentation on held-out generated images (Sec. 5.4). Whether adaptation on generated pairs improves segmentation on independent real specimens remains open.

Conclusion

We presented SF-Flow, which generates labeled scientific images from truly unpaired material maps and experimental scans by sampling a frozen flow-matching prior under a per-image spectral constraint and a cohort-level MMD constraint. Unlike unpaired translation, it does not require the simulated and real collections to share feature sizes or densities, because content comes from the map and only appearance comes from the data. Across synchrotron, laboratory microCT, and industrial X-ray tomography, the same procedure, without instrument-specific modeling, achieved higher structural agreement than C-CUT at a modest fidelity cost. Because segmentation here is a measurement, labelfaithful synthetic data matters beyond benchmark accuracy: it determines the accuracy of downstream porosity, phase fractions, and defect statistics.

LLM Usage Statement

We used large language models to assist in drafting and revising the manuscript for clarity and readability. We take full responsibility for reviewing all AI-assisted material and for the final content of the paper.

Experimental Protocol

Synchrotron Concrete

Training and sampling. The U-Net has base width 64, channel multipliers (1,2,4,4)(1, 2, 4, 4), and two residual blocks per level. We train with AdamW at batch size 16. The learning rate rises to 2×10−42 \times10^{-4} over 1,000 steps and decays to 2×10−52 \times10^{-5} on a cosine schedule.

The 256×256256 \times256 ablations use the 140k EMA checkpoint, seed 123, and 80 Heun steps. Unless varied, B=8B = 8, γ=1.25\gamma= 1.25, and the spectral budget decreases from 0.08 to 0.02 with c=0.06c = 0.06 and w=0.01w = 0.01. We correct every second step over t=0.30t = 0.30 to 1.00 and project the integrated endpoint before encoding. Each solve allows 50 iterations with primal and dual learning rates of 0.01 and 0.2 and σd=0.1\sigma_d = 0.1.

Targets and evaluation. The calibrated mean intensities on [0,1][0, 1] are 0.4465 for pore, 0.5917 for paste, and 0.6534 for main structure. Projection and spectral evaluation use a template smoothed with a one-pixel Gaussian. MS-SSIM [35] uses the unsmoothed template. The MMD reference set contains 2,048 real images disjoint from the pseudo-label source images, and the generated feature cache holds up to 500 images. FID [13] and MS-SSIM use 8-bit images. FID uses original Inception-v3 features and float64 covariance statistics unless noted. We use R=172.862R = 172.862 throughout and compare HRH_R within each dataset and resolution.

Selection and Baselines

We selected configurations on the same 500-map cohort used for Table 1. Among the 18 terminal SF-Flow configurations in the original comparison, B=8B = 8, ϵfinal=0.01\epsilon_{\mathrm{final}} = 0.01, and γ=1.25\gamma= 1.25 gave the highest HRH_R. Both single-constraint rows use B=8B = 8: spectral-only retains ϵfinal=0.01\epsilon_{\mathrm{final}} = 0.01, and MMD-only retains γ=1.25\gamma= 1.25. Table A1 reports the separate sweeps over batch size and constraint budget.

The highest HRH_R selected epochs 60 and 120 for standard and soft-boundary C-CUT [44], respectively. All hard-boundary C-CUT checkpoints had HR=0H_R = 0, so we chose epoch 50 by lowest FID. UNSB uses the 200k checkpoint. Figure 3 uses the Table 1 settings and a common grayscale range of [0,255][0, 255].

PDM [4] uses a separate 200k EMA score model and 500 spectrally projected Langevin updates with an unsmoothed template and transition width 0.02. PCFM [33] uses 80 Euler steps with our flow prior, spectral projector, target, and schedule. Each correction infers the noise endpoint as xt−tvθ(xt,t)x_t - t v_\theta(x_t, t).

Diffusion Translation trains one denoiser per modality on unpaired XCT images. Each image carries a domain label, and only synthetic images have material masks. Zhang et al. [39] estimate noise from the content image for style transfer. We corrupt the simulated reconstruction x0x_0 from the forward model by injecting noise. We denoise from xtx_t under the experimental-domain label, starting at t=300t = 300 for concrete, 200 for metal, and 400 for powder.

Boundary variants. At ϵfinal=0.02\epsilon_{\mathrm{final}} = 0.02, SF-Flow without boundary correction gives FID 13.910, MS-SSIM 0.8318, and HR=0.7649H_R = 0.7649. At this same budget, soft correction (λboundary=1\lambda_{\mathrm{boundary}} = 1) improves template MS-SSIM to 0.9379 and HRH_R to 0.8334, while FID worsens to 19.275. Hard correction copies a one-pixel-radius band without blending. All protected pixels matched the 16-bit source.

Higher Resolution and Additional Datasets

For Table 2, SF-Flow uses the 95k raw checkpoint at 512×512512 \times512 and the 80k EMA checkpoint at 1024×10241024 \times1024. C-CUT uses epochs 260 and 400, respectively. One 1024×10241024 \times1024 C-CUT file was empty, leaving 499 readable image–map pairs. At that resolution, we trained the flow-matching prior on shifted crops while C-CUT on unshifted ones. To match the distribution, we computed FID using 3,696 shifted real crops for SF-Flow and 2,816 unshifted real crops for C-CUT.

Metal and powder. Each dataset contributes 500 binary maps at 256×256256 \times256. We estimate class means from training image–mask pairs, excluding images paired with test maps. SF-Flow and PCFM use the 90k flow EMA checkpoint for metal and the 55k flow EMA checkpoint for powder. PDM uses the 200k diffusion EMA checkpoint for each dataset. Both SF-Flow runs use γ=0.10\gamma= 0.10, ϵfinal=0.02\epsilon_{\mathrm{final}} = 0.02, and 2,048 real MMD references. FID uses 10,000 real metal images and 6,108 real powder images. All C-CUT variants use epoch 400. Figure 6 uses a common grayscale window within each dataset.

SAM Adaptation

We trained the SAM2.1 Large mask decoder for 20 epochs at learning rate 10−510^{-5} and effective batch size eight, keeping the other weights fixed. Within-domain validation selected epoch 14 for generated training images and epoch 20 for simulated training images. All models used CPU float32 for inference and for computing macro IoU and Dice against the original component masks.

Sampling Ablations

Constraint Budgets and Seed Variability

In Table A1, tightening the spectral budget raises template MS-SSIM and FID at every batch size. Tightening the MMD threshold consistently lowers FID at B=1B = 1 and B=2B = 2 over the range shown. Each batch size uses its own noise draws and MMD calibration.

Fixed-setting repeats. Across ten seeds with 500 maps each (B=8B = 8, ϵfinal=0.02\epsilon_{\mathrm{final}} = 0.02, γ=1.25\gamma= 1.25 where applicable), mean FID and sample standard deviation were 9.365±0.2909.365 \pm0.290 for unconditional sampling, 46.814±0.84246.814 \pm0.842 for spectral-only, 9.334±0.1769.334 \pm0.176 for MMD-only, and 14.148±0.29014.148 \pm0.290 for SF-Flow. For Table 1, we selected SF-Flow by HRH_R and matched the single-constraint ablations to its batch size and remaining constraint setting.

Verification after terminal projection. The paired terminal runs hold the pre-correction feature history fixed. When intermediate guidance continued through t=1t = 1, terminal correction changed FID from 13.989 to 13.993. When guidance ended at t=0.80t = 0.80, the same correction raised FID from 12.999 to 96.856. At tend=0.65t_{\mathrm{end}} = 0.65, one batch exhausted all 50 iterations without a jointly feasible candidate.

Joint Sampling and Terminal Projection

Table A2 varies the batch size, budgets, template smoothing width σ\sigma (pixels), and end of intermediate guidance tendt_{\mathrm{end}}. At B=4B = 4, tightening the MMD threshold lowers both FID and template MS-SSIM at the two tested spectral budgets of 0.02 and 0.03. The best follow-up HRH_R was 0.7882 (B=4B = 4, ϵfinal=0.01\epsilon_{\mathrm{final}} = 0.01, γ=1\gamma= 1), above the 0.7842 selected in the original comparison.

References

  1. [1]Heli Ben-Hamu, Omri Puny, Itai Gat, Brian Karrer, Uriel Singer, and Yaron Lipman. D-flow: Differentiating through flows for controlled generation. In Proceedings of the 41st International Conference on Machine Learning, pages 3462–3483. PMLR, 2024. 3arxiv.org/abs/2402.14017
  2. [2]Benjamin Billot, Douglas N Greve, Oula Puonti, Axel Thielscher, Koen Van Leemput, Bruce Fischl, Adrian V Dalca, Juan Eugenio Iglesias, et al. Synthseg: Segmentation of brain mri scans of any contrast and resolution without retraining. Medical image analysis, 86:102789, 2023. 2DOI
  3. [3]Mikołaj Binkowski, Danica J Sutherland, Michael Arbel, and Arthur Gretton. Demystifying mmd gans. In International Conference on Learning Representations, 2018. 3, 5arxiv.org/abs/1801.01401
  4. [4]Jacob K Christopher, Stephen Baek, and Ferdinando Fioretto. Constrained synthesis with projected diffusion models. In Advances in Neural Information Processing Systems, pages 89307–89333, 2024. 3, 6, 7, 11arxiv.org/abs/2402.03559
  5. [5]Jacob K Christopher, James E Warner, and Ferdinando Fioretto. Constraint-aware flow matching: Decision aligned end-to-end training for constrained sampling. arXiv preprint arXiv:2605.12754, 2026. 3arxiv.org/abs/2605.12754
  6. [6]Hyungjin Chung, Jeongsol Kim, Michael T. McCann, Marc L. Klasky, and Jong Chul Ye. Diffusion posterior sampling for general noisy inverse problems. In International Conference on Learning Representations, 2023. 3arxiv.org/abs/2209.14687
  7. [7]Joseph Paul Cohen, Margaux Luck, and Sina Honari. Distribution matching losses can hallucinate features in medical image translation. In International conference on medical image computing and computer-assisted intervention, pages 529–536. Springer, 2018. 1, 2DOI
  8. [8]Chichen Fu, Soonam Lee, David Joon Ho, Shuo Han, Paul Salama, Kenneth W. Dunn, and Edward J. Delp. Three dimensional fluorescence microscopy image synthesis and segmentation. In IEEE/CVF Conference on Computer Vision and Pattern Recognition Workshops (CVPRW), pages 2221–2229, 2018. 2DOI
  9. [9]Fu, H., Gong, M., Wang, C., Batmanghelich, K., Zhang, K., & Tao, D. (2019). Geometry-consistent generative adversarial networks for one-sided unsupervised domain mapping. In IEEE/CVF conference on computer vision and pattern recognition (CVPR) (pp. 2422–2431).
  10. [10]Cao, R. G., Woods, R. E., & al., . et . (2002). Digital image processing.
  11. [11]Ian J Goodfellow, Jean Pouget-Abadie, Mehdi Mirza, Bing Xu, David Warde-Farley, Sherjil Ozair, Aaron Courville, and Yoshua Bengio. Generative adversarial nets. Advances in neural information processing systems, 27, 2014. 2
  12. [12]Arthur Gretton, Karsten M Borgwardt, Malte J Rasch, Bernhard Schölkopf, and Alexander Smola. A kernel two-sample test. The journal of machine learning research, 13:723–773, 2012. 2, 3, 5, 6, 7DOI
  13. [13]Martin Heusel, Hubert Ramsauer, Thomas Unterthiner, Bernhard Nessler, and Sepp Hochreiter. Gans trained by a two time-scale update rule converge to a local Nash equilibrium. Advances in neural information processing systems, 30, 2017. 2, 6, 11arxiv.org/abs/1706.08500
  14. [14]Jonathan Ho, Ajay Jain, and Pieter Abbeel. Denoising diffusion probabilistic models. Advances in neural information processing systems, 33:6840–6851, 2020. 2arxiv.org/abs/2006.11239
  15. [15]Zhiwei Jia, Bodi Yuan, Kangkang Wang, Hong Wu, David Clifford, Zhiqiang Yuan, and Hao Su. Semantically robust unpaired image translation for data with unmatched semantics statistics. In 2021 IEEE/CVF International Conference on Computer Vision (ICCV), pages 14253–14263. IEEE, 2021. 2arxiv.org/abs/2012.04932
  16. [16]Bezalel Kawar, Michael Elad, Stefano Ermon, and Jiaming Song. Denoising diffusion restoration models. Advances in neural information processing systems, 35:23593–23606, 2022. 3arxiv.org/abs/2201.11793
  17. [17]Steve Kench and Samuel J Cooper. Generating three-dimensional structures from a two-dimensional slice with generative adversarial network-based dimensionality expansion. Nature Machine Intelligence, 3(4):299–305, 2021. 1DOI
  18. [18]Beomsu Kim, Gihyun Kwon, Kwangyoung Kim, and Jong Chul Ye. Unpaired image-to-image translation via neural schrödinger bridge. In International Conference on Learning Representations, pages 19312–19331, 2024. 6, 7arxiv.org/abs/2305.15086
  19. [19]Kirillov, A., Mintun, E., Ravi, N., Mao, H., Rolland, C., Gustafson, L., Xiao, T., Whitehead, S., Berg, A. C., Lo, W.-Y., & al., . et . (2023). Segment anything. In 2023 IEEE/CVF international conference on computer vision (ICCV) (pp. 3992–4003).
  20. [20]Kang-Hyun Lee and Gun Jin Yun. Microstructure reconstruction using diffusion-based generative models. Mechanics of Advanced Materials and Structures, 31(18):4443–4461, 2024. 1, 2arxiv.org/abs/2211.10949
  21. [21]Yujia Li, Kevin Swersky, and Rich Zemel. Generative moment matching networks. In Proceedings of the 32nd International Conference on Machine Learning, pages 1718–1727. PMLR, 2015. 3arxiv.org/abs/1502.02761
  22. [22]Liang, J., Sun, Y., Samaddar, A., Madreddy, S., & Fioretto, F. (2025). Chance-constrained flow matching for high-fidelity constraint-aware generation. In arXiv preprint.arXiv
  23. [23]Lipman, Y., Chen, R. T. Q., Ben-Hamu, H., Nickel, M., & Le, M. (2023). Flow matching for generative. International Conference on Learning Representations.
  24. [24]Xingchao Liu, Chengyue Gong, and Qiang Liu. Flow straight and fast: Learning to generate and transfer data with rectified flow. In *International Conference on Learning Representations*, 2023. 2, 6, 7arxiv.org/abs/2209.03003
  25. [25]Andreas Lugmayr, Martin Danelljan, Andres Romero, Fisher Yu, Radu Timofte, and Luc Van Gool. Repaint: Inpainting using denoising diffusion probabilistic models. In *2022 IEEE/CVF conference on computer vision and pattern recognition (CVPR)*, pages 11451–11461. IEEE, 2022. 3arxiv.org/abs/2201.09865
  26. [26]Lukas Mosser, Olivier Dubrule, and Martin J Blunt. Reconstruction of three-dimensional porous media using generative adversarial neural networks. *Physical Review E*, 96(4): 043309, 2017. 2DOI
  27. [27]Taesung Park, Ming-Yu Liu, Ting-Chun Wang, and Jun-Yan Zhu. Semantic image synthesis with spatially-adaptive normalization. In *2019 IEEE/CVF conference on computer vision and pattern recognition (CVPR)*, pages 2332–2341. IEEE, 2019. 2arxiv.org/abs/1903.07291
  28. [28]Taesung Park, Alexei A Efros, Richard Zhang, and Jun-Yan Zhu. Contrastive learning for unpaired image-to-image translation. In *European conference on computer vision*, pages 319–345. Springer, 2020. 1, 2arxiv.org/abs/2007.15651
  29. [29]Ravi, N., Gabeur, V., Hu, Y.-T., Hu, R., Ryali, C., Ma, T., Khedr, H., Radle, R., Rolland, C., Gustafson, L., & al., . et . (2025). Sam 2: Segment anything in images and videos. International Conference on Learning Representations, 28085–28128.
  30. [30]Robin Rombach, Andreas Blattmann, Dominik Lorenz, Patrick Esser, and Björn Ommer. High-resolution image synthesis with latent diffusion models. In *2022 IEEE/CVF conference on computer vision and pattern recognition (CVPR)*, 2022. 2arxiv.org/abs/2112.10752
  31. [31]Yang Song, Jascha Sohl-Dickstein, Diederik P Kingma, Abhishek Kumar, Stefano Ermon, and Ben Poole. Score-based generative modeling through stochastic differential equations. *arXiv preprint arXiv:2011.13456*, 2020. 2arXiv
  32. [32]Anika Tabassum and Amirkoushyar Ziabari. Adapting segment anything model (SAM) to experimental datasets via fine-tuning on GAN-based simulation: A case study in additive manufacturing. In *NeurIPS 2024 Workshop on Foundation Models for Science*, 2024. arXiv:2412.11381. 1, 2arXiv
  33. [33]Utkarsh Utkarsh, Pengfei Cai, Alan Edelman, Rafael Gomez-Bombarelli, and Christopher Rackauckas. Physics-constrained flow matching: Sampling generative models with hard constraints. In *Advances in Neural Information Processing Systems*, pages 160217–160252, 2025. 3, 6, 7, 11arxiv.org/abs/2506.04171
  34. [34]Yinhua Wang, Jiwen Yu, and Jian Zhang. Zero-shot image restoration using denoising diffusion null-space model. In *International Conference on Learning Representations*, 2023. 3arxiv.org/abs/2212.00490
  35. [35]Zhou Wang, Eero P Simoncelli, and Alan C Bovik. Multiscale structural similarity for image quality assessment. In *The thirty-seventh asilomar conference on signals, systems & computers*, 2003, pages 1398–1402. IEEE, 2003. 6, 11DOI
  36. [36]Zijiang Yang, Xiaolin Li, L Catherine Brinson, Alok N Choudhary, Wei Chen, and Ankit Agrawal. Microstructural materials design via deep adversarial learning methodology. *Journal of Mechanical Design*, 140(11):111416, 2018. 2DOI
  37. [37]Stefano Zampini, Jacob K Christopher, Luca Oneto, Davide Anguita, and Ferdinando Fioretto. Training-free constrained generation with stable diffusion models. In *Advances in Neural Information Processing Systems*, pages 27285–27316, 2025. 3arxiv.org/abs/2502.05625
  38. [38]Zhang, E., & al., . et . (2026). Structure-guided masked autoencoders for ultra-high resolution scientific image understanding. In arXiv preprint arXiv:2609.30682. arXiv:2609.30682
  39. [39]Yuxin Zhang, Nisha Huang, Fan Tang, Haibin Huang, Chongyang Ma, Weiming Dong, and Changsheng Xu. Inversion-based style transfer with diffusion models. In *2023 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)*, pages 10146–10156. IEEE, 2023. 6, 7, 11arxiv.org/abs/2211.13203
  40. [40]Yasi Zhang, Peiyu Yu, Yaxuan Zhu, Yingshan Chang, Feng Gao, Ying N Wu, and Oscar Leong. Flow priors for linear inverse problems via iterative corrupted trajectory matching. In *Advances in Neural Information Processing Systems*, pages 57389–57417, 2024. 3arxiv.org/abs/2405.18816
  41. [41]Jun-Yan Zhu, Taesung Park, Phillip Isola, and Alexei A Efros. Unpaired image-to-image translation using cycle-consistent adversarial networks. In *2017 IEEE international conference on computer vision (ICCV)*, pages 2242–2251. IEEE, 2017. 1, 2arxiv.org/abs/1703.10593
  42. [42]Amirkoushyar Ziabari, Singanallur V. Venkatakrishnan, Michael Kirka, Paul Brackman, Ryan Dehoff, Philip R. Bingham, and Vincent Paquit. Beam hardening artifact reduction in X-ray CT reconstruction of 3D printed metal parts leveraging deep learning and CAD models. In *ASME International Mechanical Engineering Congress and Exposition (IMECE)*, page V02BT02A043, 2020. 2DOI
  43. [43]Amirkoushyar Ziabari, Singanallur V. Venkatakrishnan, Abhishek Dubey, Alex Lisovich, Paul Brackman, Curtis Frederick, Pradeep Bhattad, Philip Bingham, Alex Plotkowski, Ryan Dehoff, and Vincent Paquit. Simurgh: A framework for CAD-driven deep learning based X-ray CT reconstruction. In *IEEE International Conference on Image Processing (ICIP)*, pages 3863–3867, 2022. 1, 2DOI
  44. [44]Amirkoushyar Ziabari, Anika Tabassum, Muralikrishnan Gopalakrishnan Meena, and Anami Cheniour. Constrained gan-generated x-ray ct data for self-supervised and foundation-model segmentation of concrete microstructures. In *2025 IEEE International Conference on Image Processing (ICIP)*, pages 1948–1953. IEEE, 2025. 1, 2, 6, 7, 11DOI

Paper details

vlnc:W_mr3fujct
Version
v1 · latest
Published
Fresh — added to the Hub within the last 30 days
Added
License
CC BY 4.0
Usage

views · 8

downloads · 0

A view counts once per browser per day, a download each time the PDF is requested.

  • Computer Science

large language models

View statement
Looking for related papers…
Contents