{"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/scaling-for-training-time-and-post-hoc-out-of","title":"Scaling for Training Time and Post-hoc Out-of-distribution Detection Enhancement","arxiv_id":"2310.00227","date":"2023-09-30","proceeding":null,"authors":["Kai Xu","Rongyu Chen","Gianni Franchi","Angela Yao"],"abstract":"The capacity of a modern deep learning system to determine if a sample falls within its realm of knowledge is fundamental and important. In this paper, we offer insights and analyses of recent state-of-the-art out-of-distribution (OOD) detection methods - extremely simple activation shaping (ASH). We demonstrate that activation pruning has a detrimental effect on OOD detection, while activation scaling enhances it. Moreover, we propose SCALE, a simple yet effective post-hoc network enhancement method for OOD detection, which attains state-of-the-art OOD detection performance without compromising in-distribution (ID) accuracy. By integrating scaling concepts into the training process to capture a sample's ID characteristics, we propose Intermediate Tensor SHaping (ISH), a lightweight method for training time OOD detection enhancement. We achieve AUROC scores of +1.85\\% for near-OOD and +0.74\\% for far-OOD datasets on the OpenOOD v1.5 ImageNet-1K benchmark. Our code and models are available at https://github.com/kai422/SCALE.","url_abs":"https://arxiv.org/abs/2310.00227v1","url_pdf":"https://arxiv.org/pdf/2310.00227v1.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":"scaling-for-training-time-and-post-hoc-out-of","repo_url":"https://github.com/kai422/scale","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"ood-detection","task_name":"Out of Distribution (OOD) Detection"},{"task_slug":"out-of-distribution-detection","task_name":"Out-of-Distribution Detection"}],"methods":[{"method_slug":"pruning","method_name":"Pruning"}],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/out-of-distribution-detection-on-far-ood","task":"Out-of-Distribution Detection","dataset":"Far-OOD","model":"ISH (ResNet50)","rank_in_archive_order":1,"of":2,"metrics":{"AUROC":"96.79","FPR@95":"15.62","ID ACC":"76.74"},"uses_additional_data":false},{"leaderboard":"/sota/out-of-distribution-detection-on-far-ood","task":"Out-of-Distribution Detection","dataset":"Far-OOD","model":"SCALE (ResNet50)","rank_in_archive_order":2,"of":2,"metrics":{"AUROC":"96.53","FPR@95":"16.53","ID ACC":"76.18"},"uses_additional_data":false},{"leaderboard":"/sota/out-of-distribution-detection-on-imagenet-1k-12","task":"Out-of-Distribution Detection","dataset":"ImageNet-1k vs Curated OODs (avg.)","model":"SCALE (ResNet50)","rank_in_archive_order":3,"of":16,"metrics":{"AUROC":"95.71","FPR95":"20.05"},"uses_additional_data":false},{"leaderboard":"/sota/out-of-distribution-detection-on-imagenet-1k-9","task":"Out-of-Distribution Detection","dataset":"ImageNet-1k vs Places","model":"SCALE (ResNet50)","rank_in_archive_order":5,"of":25,"metrics":{"AUROC":"92.26","FPR95":"34.51"},"uses_additional_data":false},{"leaderboard":"/sota/out-of-distribution-detection-on-imagenet-1k-8","task":"Out-of-Distribution Detection","dataset":"ImageNet-1k vs SUN","model":"SCALE (ResNet50)","rank_in_archive_order":4,"of":22,"metrics":{"AUROC":"95.02","FPR95":"23.27"},"uses_additional_data":false},{"leaderboard":"/sota/out-of-distribution-detection-on-imagenet-1k-10","task":"Out-of-Distribution Detection","dataset":"ImageNet-1k vs Textures","model":"SCALE (ResNet50)","rank_in_archive_order":5,"of":34,"metrics":{"AUROC":"97.37","FPR95":"12.93","Latency, ms":"11.27"},"uses_additional_data":false},{"leaderboard":"/sota/out-of-distribution-detection-on-imagenet-1k-3","task":"Out-of-Distribution Detection","dataset":"ImageNet-1k vs iNaturalist","model":"SCALE (ResNet50)","rank_in_archive_order":6,"of":28,"metrics":{"AUROC":"98.17","FPR95":"9.5","Latency, ms":"11.27"},"uses_additional_data":false},{"leaderboard":"/sota/out-of-distribution-detection-on-near-ood","task":"Out-of-Distribution Detection","dataset":"Near-OOD","model":"ISH (ResNet50)","rank_in_archive_order":1,"of":2,"metrics":{"AUROC":"84.01","FPR@95":"55.73","ID ACC":"76.74"},"uses_additional_data":false},{"leaderboard":"/sota/out-of-distribution-detection-on-near-ood","task":"Out-of-Distribution Detection","dataset":"Near-OOD","model":"SCALE (ResNet50)","rank_in_archive_order":2,"of":2,"metrics":{"AUROC":"81.36","FPR@95":"59.76","ID ACC":"76.18"},"uses_additional_data":false}],"syntology":{"syntology_url":null,"atlas_url":"https://app.syntology.ai/?focus=2310.00227","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2310.00227"}},"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":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/kai422/scale","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"unverified":1},"by_repo_kind":{"official":{"samples":1,"ran":0,"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":"038b08510621e6a6","entry":"scale","repo":"kai422/scale","repo_kind":"official","path":"openood/networks/scale_net.py","file_url":"https://github.com/kai422/scale/blob/HEAD/openood/networks/scale_net.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"038b08510621e6a6"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}