Papers › RealNet: A Feature Selection Network with Realistic Synthetic Anomaly for Anomaly Detection

RealNet: A Feature Selection Network with Realistic Synthetic Anomaly for Anomaly Detection

9 Mar 2024CVPR 2024 1arXiv:2403.05897archive 2025-07-28

Ximiao Zhang, Min Xu, Xiuzhuang Zhou

Self-supervised feature reconstruction methods have shown promising advances in industrial image anomaly detection and localization. Despite this progress, these methods still face challenges in synthesizing realistic and diverse anomaly samples, as well as addressing the feature redundancy and pre-training bias of pre-trained feature. In this work, we introduce RealNet, a feature reconstruction network with realistic synthetic anomaly and adaptive feature selection. It is incorporated with three key innovations: First, we propose Strength-controllable Diffusion Anomaly Synthesis (SDAS), a diffusion process-based synthesis strategy capable of generating samples with varying anomaly strengths that mimic the distribution of real anomalous samples. Second, we develop Anomaly-aware Features Selection (AFS), a method for selecting representative and discriminative pre-trained feature subsets to improve anomaly detection performance while controlling computational costs. Third, we introduce Reconstruction Residuals Selection (RRS), a strategy that adaptively selects discriminative residuals for comprehensive identification of anomalous regions across multiple levels of granularity. We assess RealNet on four benchmark datasets, and our results demonstrate significant improvements in both Image AUROC and Pixel AUROC compared to the current state-o-the-art methods. The code, data, and models are available at https://github.com/cnulab/RealNet.

PaperPDFConference PDFCodeCode Syntology ran

In Syntology Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, Syntology's MCP tool lists every function and class Syntology harvested from this paper and whether it ran (how to connect): get_harvested_code_for_paper(arxiv_id="2403.05897")

Code

Syntology Ran 9 of 10 code samples harvested from 1 repository linked to this paper; 1 has no recorded run. Of those that ran: 9 ran with no contract checked.

By repository: official repository: 10 samples from 1 repository, 9 ran. The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.

cnulab/realnet officialmentioned in papermentioned on GitHubpytorchMIT report

Repository list and official/mentioned flags are the archive's, frozen 2025-07-28. Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

Code Syntology ran Syntology

10 samples harvested; 9 ran; 0 honoured the contract we drafted; 1 has no recorded run. Read from Syntology's graph 2026-09-24; that is when this build read the record, not when the samples ran.

9ran
1unverified

Licence: 0 of the 10 samples are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.

Harvested from cnulab/RealNet. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself; “our draft was wrong” and “fixture could not drive it” are failures of Syntology's instrument, not of the code.

Each sample ends with its code_sha256, Syntology's identity for that exact code. An agent fetches the stored sample with Syntology's MCP tool get_code(code_sha256="…") (how to connect); click an identity to copy that call.

Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted. community: Not in the archive's code links for this paper; a community repository Syntology harvested. Samples from a repository marked official are listed first. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of four reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; or the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar). Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.

SDAS_sample cnulab/RealNet/train_diffusion.py official repository ran MIT (permissive) · c46ea6fc2bd50337 · report
build_image_reader cnulab/RealNet/datasets/image_reader.py official repository ran MIT (permissive) · 02edfca0848f4ad3 · report
compute_top_k cnulab/RealNet/train_classifier.py official repository ran MIT (permissive) · f85c45c8d1765da4 · report
rand_perlin_2d_np cnulab/RealNet/datasets/realnet_dataset.py official repository ran MIT (permissive) · 4bb5faf95cfc1665 · report
random_between_a_and_b cnulab/RealNet/sample.py official repository ran fingerprinted MIT (permissive) · 38a9840dccf671bd · report
update_config cnulab/RealNet/train_realnet.py official repository ran MIT (permissive) · 3e33555f9dc00ec5 · report
update_config cnulab/RealNet/sample.py official repository ran MIT (permissive) · 4102f1fdf8eafea4 · report
update_config cnulab/RealNet/train_classifier.py official repository ran MIT (permissive) · 0402f903a58abc8a · report
update_config cnulab/RealNet/train_diffusion.py official repository ran MIT (permissive) · 39f7b5d3324b349c · report
lerp_np cnulab/RealNet/datasets/realnet_dataset.py official repository unverified MIT (permissive) · 4de91a4627a51ea2 · report

Tasks

Anomaly Detectionfeature selection

Results from the paper archive 2025-07-28

TaskDatasetModelMetricValueRank at snapshotLeaderboardReport
Anomaly Detection BTAD RealNet Detection AUROC 96.1 #3 of 15 Archive leaderboard report
Anomaly Detection BTAD RealNet Segmentation AUROC 97.9 #3 of 15 Archive leaderboard report
Anomaly Detection MPDD RealNet Detection AUROC 96.3 #8 of 16 Archive leaderboard report
Anomaly Detection MPDD RealNet Segmentation AUROC 98.2 #8 of 16 Archive leaderboard report
Anomaly Detection MVTec AD RealNet Detection AUROC 99.6 #21 of 148 Archive leaderboard report
Anomaly Detection MVTec AD RealNet Segmentation AUPRO 93.0 #21 of 148 Archive leaderboard report
Anomaly Detection MVTec AD RealNet Segmentation AUROC 99.0 #21 of 148 Archive leaderboard report
Anomaly Detection VisA RealNet Detection AUROC 97.8 #12 of 50 Archive leaderboard report
Anomaly Detection VisA RealNet Segmentation AUROC 98.8 #12 of 50 Archive leaderboard report

Ranks are positions in the archive's leaderboards as they stood at the 2025-07-28 snapshot. Results published since then are not among these rows, so a rank here is not a current standing.

Methods

Diffusion

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections