{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/zero-shot-anomaly-detection-via-batch-1","title":"Zero-Shot Anomaly Detection via Batch Normalization","arxiv_id":"2302.07849","date":"2023-02-15","proceeding":"NeurIPS 2023 11","authors":["Aodong Li","Chen Qiu","Marius Kloft","Padhraic Smyth","Maja Rudolph","Stephan Mandt"],"abstract":"Anomaly detection (AD) plays a crucial role in many safety-critical application domains. The challenge of adapting an anomaly detector to drift in the normal data distribution, especially when no training data is available for the \"new normal,\" has led to the development of zero-shot AD techniques. In this paper, we propose a simple yet effective method called Adaptive Centered Representations (ACR) for zero-shot batch-level AD. Our approach trains off-the-shelf deep anomaly detectors (such as deep SVDD) to adapt to a set of inter-related training data distributions in combination with batch normalization, enabling automatic zero-shot generalization for unseen AD tasks. This simple recipe, batch normalization plus meta-training, is a highly effective and versatile tool. Our theoretical results guarantee the zero-shot generalization for unseen AD tasks; our empirical results demonstrate the first zero-shot AD results for tabular data and outperform existing methods in zero-shot anomaly detection and segmentation on image data from specialized domains. Code is at https://github.com/aodongli/zero-shot-ad-via-batch-norm","url_abs":"https://arxiv.org/abs/2302.07849v4","url_pdf":"https://arxiv.org/pdf/2302.07849v4.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"zero-shot-anomaly-detection-via-batch-1","repo_url":"https://github.com/aodongli/zero-shot-ad-via-batch-norm","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"anomaly-detection","task_name":"Anomaly Detection"},{"task_slug":"unsupervised-anomaly-detection","task_name":"Unsupervised Anomaly Detection"},{"task_slug":"zero-shot-generalization","task_name":"Zero-shot Generalization"},{"task_slug":"zero-shot-anomaly-detection","task_name":"zero-shot anomaly detection"}],"methods":[{"method_slug":"batch-normalization","method_name":"Batch Normalization"}],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/anomaly-detection-on-mvtec-ad","task":"Anomaly Detection","dataset":"MVTec AD","model":"ACR (zero-shot)","rank_in_archive_order":121,"of":148,"metrics":{"Detection AUROC":"85.8","Segmentation AP":"38.9","Segmentation AUPRO":"72.7","Segmentation AUROC":"92.5"},"uses_additional_data":false},{"leaderboard":"/sota/unsupervised-anomaly-detection-on-anoshift","task":"Unsupervised Anomaly Detection","dataset":"AnoShift","model":"ACR-NTL (zero-shot, test anomaly ratio=1%)","rank_in_archive_order":1,"of":15,"metrics":{"ROC-AUC FAR":"62.5"},"uses_additional_data":false},{"leaderboard":"/sota/unsupervised-anomaly-detection-on-anoshift","task":"Unsupervised Anomaly Detection","dataset":"AnoShift","model":"ACR-DSVDD (zero-shot, anomaly ratio=1%)","rank_in_archive_order":2,"of":15,"metrics":{"ROC-AUC FAR":"62"},"uses_additional_data":false},{"leaderboard":"/sota/unsupervised-anomaly-detection-on-anoshift","task":"Unsupervised Anomaly Detection","dataset":"AnoShift","model":"ACR-NTL (zero-shot, test anomaly ratio=20%)","rank_in_archive_order":3,"of":15,"metrics":{"ROC-AUC FAR":"62"},"uses_additional_data":false},{"leaderboard":"/sota/unsupervised-anomaly-detection-on-anoshift","task":"Unsupervised Anomaly Detection","dataset":"AnoShift","model":"ACR-DSVDD (zero-shot, anomaly ratio=20%)","rank_in_archive_order":4,"of":15,"metrics":{"ROC-AUC FAR":"59.1"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2302.07849","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2302.07849"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"deterministic:regex_extraction","url":"https://github.com/aodongli/zero-shot-ad-via-batch-norm","reach":null}],"summary":{"ran":1},"by_repo_kind":{"official":{"samples":1,"ran":1,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"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"},"n_pointer_only_for_licence":0,"samples":[{"code_sha256_prefix":"47c477fbc4b5ecb0","entry":"DCL","repo":"aodongli/zero-shot-ad-via-batch-norm","repo_kind":"official","path":"anoshift-cifar100c-omniglot/losses/ntl_loss.py","file_url":"https://github.com/aodongli/zero-shot-ad-via-batch-norm/blob/HEAD/anoshift-cifar100c-omniglot/losses/ntl_loss.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"47c477fbc4b5ecb0"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}