{"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/bnn-bn-training-binary-neural-networks","title":"\"BNN - BN = ?\": Training Binary Neural Networks without Batch Normalization","arxiv_id":"2104.08215","date":"2021-04-16","proceeding":null,"authors":["Tianlong Chen","Zhenyu Zhang","Xu Ouyang","Zechun Liu","Zhiqiang Shen","Zhangyang Wang"],"abstract":"Batch normalization (BN) is a key facilitator and considered essential for state-of-the-art binary neural networks (BNN). However, the BN layer is costly to calculate and is typically implemented with non-binary parameters, leaving a hurdle for the efficient implementation of BNN training. It also introduces undesirable dependence between samples within each batch. Inspired by the latest advance on Batch Normalization Free (BN-Free) training, we extend their framework to training BNNs, and for the first time demonstrate that BNs can be completed removed from BNN training and inference regimes. By plugging in and customizing techniques including adaptive gradient clipping, scale weight standardization, and specialized bottleneck block, a BN-free BNN is capable of maintaining competitive accuracy compared to its BN-based counterpart. Extensive experiments validate the effectiveness of our proposal across diverse BNN backbones and datasets. For example, after removing BNs from the state-of-the-art ReActNets, it can still be trained with our proposed methodology to achieve 92.08%, 68.34%, and 68.0% accuracy on CIFAR-10, CIFAR-100, and ImageNet respectively, with marginal performance drop (0.23%~0.44% on CIFAR and 1.40% on ImageNet). Codes and pre-trained models are available at: https://github.com/VITA-Group/BNN_NoBN.","url_abs":"https://arxiv.org/abs/2104.08215v1","url_pdf":"https://arxiv.org/pdf/2104.08215v1.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":"bnn-bn-training-binary-neural-networks","repo_url":"https://github.com/VITA-Group/BNN_NoBN","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"image-classification","task_name":"Image Classification"}],"methods":[{"method_slug":"batch-normalization","method_name":"Batch Normalization"}],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/image-classification-on-cifar-10","task":"Image Classification","dataset":"CIFAR-10","model":"ReActNet-18","rank_in_archive_order":185,"of":265,"metrics":{"Percentage correct":"92.08"},"uses_additional_data":false},{"leaderboard":"/sota/image-classification-on-cifar-100","task":"Image Classification","dataset":"CIFAR-100","model":"ReActNet-18","rank_in_archive_order":181,"of":211,"metrics":{"Percentage correct":"68.34"},"uses_additional_data":false},{"leaderboard":"/sota/image-classification-on-imagenet","task":"Image Classification","dataset":"ImageNet","model":"ReActNet-A (BN-Free)","rank_in_archive_order":1036,"of":1060,"metrics":{"Top 1 Accuracy":"68.0%"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2104.08215","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2104.08215"}},"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/VITA-Group/BNN_NoBN","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"ran_draft_wrong":2,"ran_honours":1,"ran":1,"unverified":7},"by_repo_kind":{"official":{"samples":11,"ran":4,"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":"d9def42110729a85","entry":"conv1x1","repo":"VITA-Group/BNN_NoBN","repo_kind":"official","path":"models/Qa_reactnet_18_bn.py","file_url":"https://github.com/VITA-Group/BNN_NoBN/blob/HEAD/models/Qa_reactnet_18_bn.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"d9def42110729a85"}},{"code_sha256_prefix":"fac5364e2f53c6db","entry":"conv3x3","repo":"VITA-Group/BNN_NoBN","repo_kind":"official","path":"models/Qa_reactnet_18_bn.py","file_url":"https://github.com/VITA-Group/BNN_NoBN/blob/HEAD/models/Qa_reactnet_18_bn.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"fac5364e2f53c6db"}},{"code_sha256_prefix":"73876e077d3acdf5","entry":"get_padding","repo":"VITA-Group/BNN_NoBN","repo_kind":"official","path":"layers.py","file_url":"https://github.com/VITA-Group/BNN_NoBN/blob/HEAD/layers.py","link_basis":"plan_row","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":"well_formed","behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"73876e077d3acdf5"}},{"code_sha256_prefix":"670bc2732a11c7eb","entry":"unitwise_norm","repo":"VITA-Group/BNN_NoBN","repo_kind":"official","path":"agc.py","file_url":"https://github.com/VITA-Group/BNN_NoBN/blob/HEAD/agc.py","link_basis":"harvester_set","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":"670bc2732a11c7eb"}},{"code_sha256_prefix":"7fbee15b94a45d5d","entry":"binaryconv3x3","repo":"VITA-Group/BNN_NoBN","repo_kind":"official","path":"models/Qa_reactnet_18_bf.py","file_url":"https://github.com/VITA-Group/BNN_NoBN/blob/HEAD/models/Qa_reactnet_18_bf.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":"7fbee15b94a45d5d"}},{"code_sha256_prefix":"5ae551aef288dd66","entry":"cifar100_dataloaders","repo":"VITA-Group/BNN_NoBN","repo_kind":"official","path":"dataset.py","file_url":"https://github.com/VITA-Group/BNN_NoBN/blob/HEAD/dataset.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":"5ae551aef288dd66"}},{"code_sha256_prefix":"468e801161562d86","entry":"cifar10_dataloaders","repo":"VITA-Group/BNN_NoBN","repo_kind":"official","path":"dataset.py","file_url":"https://github.com/VITA-Group/BNN_NoBN/blob/HEAD/dataset.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":"468e801161562d86"}},{"code_sha256_prefix":"c40fa415189b7c0a","entry":"conv1x1","repo":"VITA-Group/BNN_NoBN","repo_kind":"official","path":"models/Qa_reactnet_18_bf.py","file_url":"https://github.com/VITA-Group/BNN_NoBN/blob/HEAD/models/Qa_reactnet_18_bf.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":"c40fa415189b7c0a"}},{"code_sha256_prefix":"20f90730b09ba843","entry":"conv3x3","repo":"VITA-Group/BNN_NoBN","repo_kind":"official","path":"models/Qa_reactnet_18_bf.py","file_url":"https://github.com/VITA-Group/BNN_NoBN/blob/HEAD/models/Qa_reactnet_18_bf.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":"20f90730b09ba843"}},{"code_sha256_prefix":"846a4b93e56bfe0b","entry":"get_weight","repo":"VITA-Group/BNN_NoBN","repo_kind":"official","path":"layers.py","file_url":"https://github.com/VITA-Group/BNN_NoBN/blob/HEAD/layers.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":"846a4b93e56bfe0b"}},{"code_sha256_prefix":"66a7c45936102f69","entry":"imagenet_dataloaders","repo":"VITA-Group/BNN_NoBN","repo_kind":"official","path":"dataset.py","file_url":"https://github.com/VITA-Group/BNN_NoBN/blob/HEAD/dataset.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":"66a7c45936102f69"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}