Diffusion models have shown potential in inverse design of printed circuit boards (PCBs), enabling the generation of layouts conditioned on target S-parameters. Despite this promise, applying diffusion models to PCB layout generation remains challenging due to their difficulty in meeting the quantitative electromagnetic specifications. A common approach is gradient-based guidance, which biases the diffusion sampling process with the gradient of an objective used for evaluation. However, full-wave electromagnetic simulators are accurate but expensive and typically non-differentiable, whereas differentiable surrogates are informative but not always reliable. To address these limitations, this paper proposes Simulator-Refined Diffusion (SRD), a novel combination of a low-fidelity differentiable surrogate and a high-fidelity non-differentiable simulator within the diffusion sampling process. Unlike standard zeroth-order optimization, which requires a great number of random perturbations, our approach uses the surrogate's gradient to propose the perturbation direction while the simulator then searches based on this direction to identify an effective design update. Experimental results across different settings show that this method consistently outperforms current state-of-the-art methods, producing layouts whose simulated S-parameters match the target specifications up to 21.2% closer for in-distribution targets and up to 19.8% for out-of-distribution targets.
Figures & tables
Figure 1: Simulator-Refined Diffusion. (a) Target S-parameters and board context condition generation. (b) At selected late denoising steps, surrogate gradients propose geometric edits (Eq. 5 ); the full-wave simulator selects the candidate to retain (Section 5.2 ). Relative to the central unedited candidate, gold-colored pixels are retained, crossed red pixels are removed, and blue-colored pixels are added. (c) Low correlation between the surrogate and the simulator downstream losses (RMSE) across tasks, observed especially in the low-loss regime and out of distribution regions.
Figure 2: Representative boards.
Test set
OOD set
Method
Mean loss ↓
Median loss ↓
Reduction (%) ↑
Sim. success (%) ↑
Palace calls
Mean loss ↓
Median loss ↓
Reduction (%) ↑
Sim. success (%) ↑
Palace calls
CD ( Dreossi et al., 2026 )
0.3222
0.2820
0.00
99.6
1
0.5418
0.6120
0.00
98.0
1
GGD ( Ye et al., 2024 )
0.3174
0.2687
1.49
98.4
1
0.5249
0.6121
3.12
96.0
1
DPO ( Zampini et al., 2025 )
0.2819
0.2441
12.51
100.0
7
0.4821
0.5403
11.02
96.0
17
SRD (adaptive)
0.2608
0.1977
19.06
100.0
7
0.4444
0.4338
17.98
98.0
17
SRD (directional)
0.2640
0.1980
18.06
100.0
7
0.4346
0.4082
19.79
98.0
17
Table 1: Comparison on the test and OOD sets. DPO and all SRD variants apply guidance during the last 2 denoising steps on the test set and the last 4 on the OOD set. Palace calls count the selection budget at each guided step plus one final Palace evaluation; CD and GGD use only the final evaluation. Reductions are relative to the mean loss of CD. Simulation success is the percentage of generated boards with a valid Palace result. For each performance metric, bold and underlined values indicate the best and second-best results, respectively.
Figure 3: Mean S-parameter loss by template on the test set. Shaded regions indicate the easy, medium, and hard target groups. Lower loss is better.
Figure 5: Quality–cost trade-off across methods.
Perturbations
Candidate selection
Performance
Method
Surrogate direction
Random
Palace
Surrogate
Mean loss ↓
Median loss ↓
Reduction (%) ↑
Ablations
×
✓✓
×
×
0.4064
0.4058
−26.14
×
✓✓
×
✓✓
0.3263
0.2986
−1.28
✓✓
×
×
✓✓
0.2873
0.2284
10.83
CD
×
×
×
×
0.3222
0.2820
0.00
DPO
×
✓✓
✓✓
×
0.2819
0.2441
12.51
Table 2: Ablations on the test set. Double checkmarks indicate components that are always used. A single checkmark indicates conditional use, and crosses indicate inactive components. Candidates use surrogate descent directions or random perturbations; selection uses Palace evaluations or surrogate predictions. Mean loss reductions are relative to CD.
Appendix figures & tables5 assets
Supplementary material from the paper’s appendix.
Appendix
Material
εr
tanδ
Thickness ( μ m)
Air (suspended)
1.00
0
203.2
Rogers RO4003
3.55
0.0027
203.2
FR-4 (S1000H)
4.60
0.011
200.0
Appendix
Table 3: Substrate properties used in simulation.
Figure 6: Intermediate layouts at denoising steps 17–19 of a 20-step sampling process for SRD (top) and CD (bottom). Both methods start from the same Frame-17 layout. Black denotes metal. Orange marks the geometric perturbations applied by SRD. Blue and aqua dots mark ports 1 and 2.
Figure 7: Nearest-neighbor distances ( k=1 ) to the training set in DINOv3 embedding space. Each point represents one sample. In the scatter plot, the horizontal axis reports the CD distance. The vertical axis reports the distance for the corresponding GGD, DPO, or SRD layout on the same target and seed. Colored contours show two-dimensional kernel density estimates (KDEs). Marginal KDE curves summarize the distance distributions along each axis. Points on the dashed diagonal indicate unchanged proximity to the training set; points above and below indicate layouts that are farther from and closer to it. This comparison shows how much each method moves layouts relative to the prior, and should be read alongside the losses in Table 1 .
Figure 8: PCB layouts and their S-parameter magnitude responses. Solid and dashed curves indicate generated and target responses, respectively.
Figure 9: Example PCB layouts generated by the three SRD variants. Each panel contains 25 layouts.
Inverse design of RF passive components from S-parameters is a high-dimensional, ill-posed problem, and prior generative approaches are limited to single-layer binary-metallization structures. This paper presents an inverse design approach that generates passive components from partial S-parameter inputs on an 8×8 mm board discretized at 64×64 pixels with sub-pixel grayscale metallization across 1-20 GHz. The framework generates two-layer copper layouts with vias, with hard physical constraints on feed locations enforced through annealed Langevin projection, flexible multi-modal conditioning on partial S-parameter specifications, port locations, dielectric properties, reference topology, and variable port placement. Candidate designs are generated in seconds, with surrogate-predicted S-parameters matching targets to within 0.77±1.28 dB weighted mean absolute error. We validate the approach with two fabricated designs on RO4003C: a manufacturable alternative to a hairpin filter whose coupling gaps violate fabrication rules, and a combline bandpass filter designed from scratch given only target S-parameters.
Tommaso Dreossi, Christopher M. Bryant, Hao Liu +4
Future wireless systems are expected to transform the surrounding space from a passive propagation medium into a smart electromagnetic environment, where engineered surfaces control wave propagation, support wireless sensing, and create programmable electromagnetic fingerprints. A key challenge in realizing this vision is the inverse design of metasurfaces for tailored electromagnetic propagation. While forward analysis evaluates the response of a known geometry, the inverse task starts from a prescribed scattering signature and seeks a physically realizable structure that produces it. This inverse task is inherently nonlinear and often high-dimensional, while candidate solutions may be non-unique and provide no direct indication of practical realizability. Here, we introduce a conditional diffusion framework for inverse design of dielectric resonator metasurfaces from target angular scattering patterns. Trained on T-matrix simulated geometry-response pairs, the model learns a conditional distribution of geometries instead of a deterministic mapping, enabling multiple candidate designs for the ill-posed inverse problem. The best generated metasurface achieves a mean percentage error of 1.39%, outperforming CMA-ES optimization (4.1% after 10 h) while requiring only about one minute for after-training inference. The model also produces lower error distributions than deterministic neural baselines for out-of-distribution spectra, highlighting the potential of diffusion models for efficient metasurface design.
Technology computer-aided design (TCAD) semiconductor device simulation is fundamentally constrained by the high computational cost of iteratively solving coupled drift-diffusion equations. Existing ML surrogates either reduce internal physics to macroscopic scalar regressions, or rely on single-step mappings that lack the iterative refinement required to resolve stiff, coupled fields. To address this, we introduce PCGD, a Physics-Guided Conditional Graph Diffusion framework operating natively on unstructured TCAD meshes to predict coupled electrostatic and carrier density fields. PCGD employs a Condition-Aware MeshGraphNet denoiser that explicitly injects boundary conditions and device structure context via global cross-attention. By augmenting data-driven denoising with a physics-guided hybrid objective that integrates exponent-free quasi-Fermi gradient matching with noise-aware PDE residuals, PCGD progressively enforce physical constraints in the iterative diffusion trajectory. This strategy successfully bypasses the numerical instabilities typical of stiff drift-diffusion equations. Evaluated on a challenging mixed PN/MOS benchmark, PCGD significantly outperforms deterministic one-step regression (1.207% error) and local diffusion (1.585% error) baselines by achieving a sub-percent mean relative field error of 0.835%, while concurrently reducing maximum PDE residual errors by nearly three orders of magnitude compared to pure diffusion. It also transfers robustly to unseen SOI topologies (0.815% error) via LoRA adaptation, using 5.30× less data and 14.34× fewer parameters than full fine-tuning. Ultimately, PCGD bridges the computational efficiency of generative surrogates with the rigorous physical fidelity of traditional TCAD, unlocking highly scalable, field-level analysis for robust device engineering.