Forgery-Detection Audits for Machine-Read Stacking in 2D Magnets

In layered magnets, the way two atomic sheets sit on top of each other can decide whether their spins align or oppose. Bilayer chromium triiodide is ferromagnetic in one stacking and antiferromagnetic in another that is only a small lateral slide away. Machine-learning models can now read this stacking directly from electron-microscope images. They are trained mostly on simulated images that a generative model has restyled to look experimental. That training setup is the same shape as the failure that troubles deepfake detection. Deepfake detectors score near-perfectly on their own benchmark and then collapse on new data, because they learned fingerprints of the image-making pipeline rather than the property they were meant to detect. This note proposes to bring the forgery-detection field's diagnostic and corrective tools to bear on that structural risk. The aim is to check whether stacking-from-image models learn the restyling generator's fingerprints instead of atomic positions, and whether removing those fingerprints reduces the number of wrong ferromagnetic-versus-antiferromagnetic calls downstream.

Put plainly: a stacking regressor trained on generator-restyled simulations may be partly a detector of the generator, just as deepfake classifiers turn out to be detectors of specific face-swap pipelines. If a small "is this restyled or truly experimental?" classifier can easily separate the training images from real ones, that separability should predict where the regressor fails. Training the regressor so that this classifier can no longer separate the two should then make its magnetic-phase predictions more reliable.

Core Claim

The closest existing work is Huang et al.. They translate simulated scanning transmission electron microscopy (STEM) images of van der Waals interfaces into experimental style using disentangled representation learning, which they call the "Trident" strategy. They then train a ResNet-50 to regress interlayer slip and twist. They report twist accuracy below 0.29° and robustness to 10% defects and PSNR as low as 7. Their scope has two limits that matter here. First, they study only non-magnetic dichalcogenides ($\text{MoS}_2$, $\text{WS}_2$, $\text{ReS}_2$, $\text{ReSe}_2$, $1\text{T}'\text{-MoTe}_2$). Second, they treat the translator as a source of data, never as a possible source of shortcuts.

Our claim has three parts. Translator-specific artifacts are measurable. Their measurability, quantified as the area under the curve (AUC) of a restyled-versus-experimental classifier built from forgery-detection architectures, predicts per-material regression error. Suppressing those artifacts reduces stacking-phase misassignment in the regime where it matters physically: near stacking boundaries where the magnetic ground state flips.

This differs from the forgery literature as well. There, the detector is the end product. Here it is an instrument for auditing and regularizing a scientific measurement model, and success is judged by a physics outcome rather than by detection accuracy.

The physics supplies a concrete success criterion, not a metaphor. Jiang et al. show with van der Waals-corrected density functional theory (DFT) that bilayer $\text{CrI}_3$ in rhombohedral stacking is ferromagnetic by 3.23 meV/Cr. In monoclinic stacking it is antiferromagnetic by 0.54 meV/Cr, with a sliding barrier of roughly 10 meV/Cr. Correct stacking assignment therefore determines the predicted magnetic order. Wang et al. show an even sharper sensitivity in $\text{CrSe}_2$, where a 0.05 Å change in interlayer spacing flips the ground state. This motivates a stress test on cross-sectional images, where layer spacing is visible. In both cases, regression error that is harmless for a non-magnetic dichalcogenide becomes a qualitative error for a magnet.

Research Program

The work proceeds in three steps.

Step 1: build the audit dataset. We generate multislice-simulated STEM images of bilayer $\text{CrI}_3$ that densely sample the slip path between rhombohedral and monoclinic registry. Following Jiang et al., each slip is labeled with its stacking class and therefore its magnetic order. We add the materials used by Huang et al. so their setting is reproduced. Each simulated set is passed through the Trident translator and, separately, through a physics-based noise and scan-distortion model. This gives two "fake experimental" sources whose artifacts differ.

Step 2: build the artifact probe. This step borrows directly from forgery detection. We train a restyled-versus-experimental classifier in two forms. The first is a patch-level network truncated after its second block. Chai et al. showed that such networks, which see only about 30×30-pixel regions, find generator fingerprints that generalize across generators. The second is a spatial-plus-frequency network in the style of Yousaf et al.. It uses Fourier and blockwise wavelet streams aimed at stationary periodic artifacts, which in STEM are dangerous because the signal itself is periodic.

We also adopt Chai et al.'s "preprocessing parity" lesson: real and synthetic images must share resampling, normalization and file-format handling. Otherwise the probe and the regressor both learn file-pipeline clues. We treat that as a first-class control, not a footnote.

Step 3: train the regressor against the probe. We train the slip and twist regressor with an added penalty that makes the probe's features uninformative about source, measured as probe AUC on held-out patches.

We also run a deliberate "laundering" test, borrowed from the forgery-detection observation that heavy video compression erases high-frequency traces (Rössler et al.; Li et al.). We low-pass filter test images at strengths that keep the atomic columns resolvable. If the baseline regressor degrades much more than physics allows, it was leaning on high-frequency translator texture.

Experimental $\text{CrI}_3$ STEM images are not in hand and would require a microscopy collaboration. The core analysis therefore runs in two places: on Huang et al.'s experimental dichalcogenide images, and on a held-out "instrument" condition in simulation, with different aberration, dose and drift parameters never seen by the translator.

Baselines

Naive reference. A ResNet-50 regressor trained on raw simulated images with only Gaussian noise added, no translation. It shows how much any sim-to-real handling buys.

Strongest existing method. The Trident pipeline of Huang et al., reimplemented with the same backbone, simulation budget, training images and hyperparameter search budget as our method. The reported figure to beat is twist error below 0.29° on their experimental benchmark. No reported result was found on Lacuna for stacking-phase or magnetic-phase classification accuracy from STEM images, so the phase-level comparison is new. Beating Trident means that on held-out experimental or held-out-instrument images we either lower phase misassignment within a band around the rhombohedral–monoclinic boundary or lower slip error there. We must do this without giving back more than noise-level accuracy elsewhere, and the twist error must stay at or below Trident's level.

Domain randomization. A non-translator baseline that heavily randomizes noise, drift and aberration in the simulator. This is the alternative a microscopist would reach for first.

Ablations. Two ablations isolate the key ingredient. The first applies preprocessing parity alone, without the probe penalty. This tests whether the gain is just the cheap parity fix. The second applies the probe penalty using only the frequency stream or only the patch stream. This tells us which artifact family carries the shortcut.

Why not just…?

Why not just trust Trident, since it already reports sub-degree accuracy and noise robustness? Its robustness tests vary defect density and signal-to-noise ratio. They do not test whether the model relies on translator texture, and they do not probe near-boundary slips where errors change the predicted magnetism. The laundering test and the probe-AUC-versus-error correlation answer this directly. If Trident shows neither a low-pass collapse nor a correlation, the shortcut hypothesis is wrong, and we report that as the result.

Why not just use domain randomization in the simulator and skip generative translation entirely? This is a real threat. Randomized physics noise has no generator fingerprint to exploit. We include it as a full baseline. If it matches the probe-regularized model on held-out conditions, the conclusion is that translation itself is the liability. That conclusion would still be useful, but it would shift the contribution from a method to a diagnosis.

Why not just fine-tune on a few labeled experimental images? Ground-truth slip labels for experimental images are exactly what is missing. A few labels from independent techniques could calibrate the model. However, Du et al. found in forgery detection that even targeted supervision on under 3% of samples leaves a generalization gap between seen and unseen distributions. We test few-shot fine-tuning on the held-out-instrument simulation, where labels exist, at matched label budgets.

Why not just classify magnetic order directly from the image? The phase label is a deterministic function of stacking, so a direct classifier discards the physics and invites the same shortcut learning. We compare it against our approach on near-boundary cases.

Proposed Experiments

Experiment 1: does the artifact probe predict regression failure? Across materials and instrument conditions, we compute the probe's AUC and the regressor's slip error. The decisive check is a positive rank correlation between the two. Absent that correlation, the audit idea fails.

Experiment 2: does suppressing artifacts help where it matters? We measure magnetic-phase misassignment along the dense $\text{CrI}_3$ slip path. Using Jiang et al.'s stacking-to-order mapping, we compare Trident, domain randomization, parity-only and the probe-penalized model. Results are reported both overall and in the near-boundary band.

Experiment 3: is the baseline leaning on high-frequency texture? We run the laundering curve: regression error against low-pass strength, for each method. A shortcut-free model should degrade only as atomic columns themselves blur.

Experiment 4: can the method resolve layer spacing at the precision magnetism demands? We use simulated cross-sectional $\text{CrSe}_2$ bilayers across the spacing range studied by Wang et al. and ask whether any method resolves spacing finely enough to call the ground state. The 0.05 Å flip in Wang et al. sets the bar. Failing it everywhere would bound what image-based inference can deliver for near-critical magnets.

Together these experiments decide whether forgery-detection practice belongs in the toolkit for machine-read structure in 2D magnets.