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.
Figures & tables
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.
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=1 precedes encoding, with no further ODE steps.
Phase hallucination (%, ↓ )
Method
HR↑
FID ↓
MS-SSIM ↑
Pore
Paste
Main struct.
SF-Flow
0.7842
14.588
0.8565
6.10
4.75
2.33
SF-Flow + soft boundary
0.8334
19.275
0.9379
11.33
2.59
1.88
SF-Flow + hard boundary
0.5326
26.028
0.6270
15.95
14.01
7.24
Flow Matching [ 24 ]
–
9.291
–
–
–
–
Spectral-only [ 10 ]
0.5097
71.578
0.8699
6.21
4.49
2.20
Table 1: Synchrotron concrete synthesis on 500 256×256 maps. Metrics measure cohort fidelity (FID), template agreement (MS-SSIM), and their combined score ( HR , 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=8 and match the corresponding constraint setting (Sec. A.2 ). Diffusion Translation is our XCT adaptation of InST [ 40 ] style-transfer approach.
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.
512×512
1024×1024
Phase hallucination (%, ↓ )
Phase hallucination (%, ↓ )
Method
HR↑
FID ↓
MS-SSIM ↑
Pore
Paste
Main struct.
HR↑
FID ↓
MS-SSIM ↑
Pore
Paste
Main struct.
SF-Flow
0.6421
35.430
0.8077
8.74
6.88
3.81
0.3591
89.835
0.7476
7.30
6.29
5.52
SF-Flow + soft boundary
0.7374
37.822
0.9439
12.79
2.19
1.91
0.4644
87.703
0.9427
10.61
2.04
2.09
SF-Flow + hard boundary
0.4383
52.917
0.6316
14.01
13.78
6.29
0.2632
101.244
0.6354
11.62
13.15
5.85
Flow Matching [ 24 ]
–
23.876
–
–
–
–
–
62.610
–
–
–
–
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 ( HR ), 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 ).
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.
XCT Concrete
XCT Metal AM
MicroCT Powder
Method
HR↑
FID ↓
MS-SSIM ↑
HR↑
FID ↓
MS-SSIM ↑
HR↑
FID ↓
MS-SSIM ↑
SF-Flow
0.7842
14.588
0.8565
0.8230
16.860
0.9120
0.8600
10.807
0.9174
SF-Flow + soft boundary
0.8334
19.275
0.9379
0.8276
17.162
0.9189
0.8729
11.596
0.9356
SF-Flow + hard boundary
0.5326
26.028
0.6270
0.7119
21.635
0.8138
0.8526
11.263
0.9120
Flow Matching [ 24 ]
–
9.291
–
–
9.957
–
–
15.421
–
C-CUT [ 42 ]
0.7165
12.314
0.7714
0.7597
11.289
0.8127
0.8409
9.770
0.8913
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 HR than all C-CUT variants, while standard or soft-boundary C-CUT retains lower FID. HR uses the fixed reference R=172.862 and is compared within datasets.
Appendix figures & tables3 assets
Supplementary material from the paper’s appendix.
Appendix
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×512 , methods share the prescribed material map in each row. (b) At 1024×1024 , 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.
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×256 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.
Phase hallucination (%, ↓ )
B
γ
HR↑
FID ↓
MS-SSIM ↑
Pore
Paste
Main struct.
1
0.50
0.5517
9.150
0.5825
97.21
60.59
42.59
1
0.75
0.5520
9.176
0.5830
97.21
60.61
42.57
1
1.00
0.5514
9.354
0.5830
97.21
60.62
42.57
1
1.25
0.5509
9.510
0.5830
97.21
60.61
42.57
2
0.50
0.5471
8.903
0.5768
96.63
58.93
44.72
Appendix
Table A1 : Single-constraint sweeps on 500 synchrotron concrete maps at 256×256 . (a) MMD-only varies the threshold multiplier γ ; (b) spectral-only varies the final residual budget ϵfinal . Smaller values tighten the corresponding constraint, and B is the sampling batch size. FID measures cohort fidelity, MS-SSIM measures agreement with the unsmoothed template, and HR 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.
Current flow matching models learn to transport the source i.i.d. Gaussian noise into the target distribution of natural images, yet this source distribution carries no notion of spatial structure. Images however are fundamentally local since nearby pixels are strongly correlated. By sampling the noise independently, we hypothesize that models are implicitly encouraged to exploit less noisy neighbors as context during training, partially bypassing the need to properly learn the true local structure of images. The source distribution, in other words, works against the inductive bias of the image domain. To ameliorate this design discrepancy, we propose StructFlow which encodes spatial locality directly into the source by having the pixels within a small region share a common noise component. This structured source produces transport paths that are geometrically aligned with image regions - enabling properties that generic flow matching struggles to provide: fine-grained local editing that naturally respects boundaries, robust structure preservation, and smooth semantic interpolation between images. We show that these benefits also extend to large pre-trained models, demonstrating that StructFlow can even be incorporated through a lightweight post-training phase. Comprehensive experiments on multiple datasets, in unconditional, class and text-conditioned regimes, using different diffusion transformer architectures confirm that StructFlow not only offers competitive image generation quality, but also significantly improves localized controllable re-synthesis.
Pixel-space generative models bypass lossy latent compression, yet necessitate joint learning of global structure and fine-grained details in a high-dimensional space. Standard flow matching interpolates noise toward a fixed clean-image endpoint, leaving the spectral evolution to be learned implicitly. In this paper, we introduce Energy-Guided Flow Matching(EG-FM) that explicitly models a coarse-to-fine generative trajectory by moving endpoint. Specifically, EG-FM replaces the fixed endpoint with a heat-kernel-filtered endpoint that evolves smoothly from low-frequency image to clean image. The fraction of high-frequency signal in moving endpoint is released by an image-specific energy-guided scheduling, leading to the re-targeting of velocity in flow matching. Our framework requires no adaptation of the backbone and training data, bringing negligible cost on the training and inference stages. In our experiment, EG-FM consistently achieves lower FID on the ImageNet class-conditional image generation task at 256×256 with fewer epochs, reaching an FID of 1.55 at 200 epochs and 1.45 at 600 epochs. We continue training the generation task on the setting of 512×512 resolution, yielding a FID of 1.58 after only 40 high-resolution adaptation epochs. Furthermore, we transfer EG-FM on text-to-image generation and achieve 0.85 on GenEval score and 83.9 on DPG-Bench. Code is available at https://github.com/ysng123/EG-FM.
Haoyang Tong, Yu He, Fang Li +6
MAIS & NLPR, CASIA · JD.com · Xi'an Jiaotong University +1
We introduce Contrast Sensitive Flow (CSFlow), a weighting scheme that connects the human eye's Contrast Sensitivity Function (CSF) to the iterative denoising steps of flow matching. Because real-world images concentrate signal at low spatial frequencies, these components reach high signal-to-noise ratio earlier during continuous diffusion than high-frequency components. When generating images with diffusion or flow matching models, this induces a soft autoregressive structure in Fourier space, where coarse image content stabilizes before fine detail. Meanwhile, the human visual system is unequally sensitive to spatial frequencies: very low and very high frequencies require significantly higher contrast to be perceived. We for the first time merge these observations through two contributions: (1) a metric that estimates which frequencies are generated at each reverse flow interval and (2) timestep weights obtained by aligning the frequencies generated at each noise level with human contrast sensitivity. We validate our contributions experimentally showing that these weights can improve generative performance by lowering FID by up to 12.15%, increasing Inception Score by up to 3.2% and improving GenEval scores by up to 3.0% using inference-only timestep modification or short fine-tuning. Qualitatively, we find that our CSFlow weights lead to better visual realism and less cartoonish appearance of generated images. In a two-alternative forced-choice study, participants preferred CSFlow generations over the baseline in 65% of comparisons. Additional visualisations, code, models and the example CSFlow weights are available on our project website.
Malgorzata Galinska, Bart Pogodzinski, Jan Eric Lenssen
Max Planck Institute for Informatics, Saarland Informatics Campus