{"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/shape-texture-debiased-neural-network-1","title":"Shape-Texture Debiased Neural Network Training","arxiv_id":"2010.05981","date":"2020-10-12","proceeding":"ICLR 2021 1","authors":["Yingwei Li","Qihang Yu","Mingxing Tan","Jieru Mei","Peng Tang","Wei Shen","Alan Yuille","Cihang Xie"],"abstract":"Shape and texture are two prominent and complementary cues for recognizing objects. Nonetheless, Convolutional Neural Networks are often biased towards either texture or shape, depending on the training dataset. Our ablation shows that such bias degenerates model performance. Motivated by this observation, we develop a simple algorithm for shape-texture debiased learning. To prevent models from exclusively attending on a single cue in representation learning, we augment training data with images with conflicting shape and texture information (eg, an image of chimpanzee shape but with lemon texture) and, most importantly, provide the corresponding supervisions from shape and texture simultaneously. Experiments show that our method successfully improves model performance on several image recognition benchmarks and adversarial robustness. For example, by training on ImageNet, it helps ResNet-152 achieve substantial improvements on ImageNet (+1.2%), ImageNet-A (+5.2%), ImageNet-C (+8.3%) and Stylized-ImageNet (+11.1%), and on defending against FGSM adversarial attacker on ImageNet (+14.4%). Our method also claims to be compatible with other advanced data augmentation strategies, eg, Mixup, and CutMix. The code is available here: https://github.com/LiYingwei/ShapeTextureDebiasedTraining.","url_abs":"https://arxiv.org/abs/2010.05981v2","url_pdf":"https://arxiv.org/pdf/2010.05981v2.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":"shape-texture-debiased-neural-network-1","repo_url":"https://github.com/LiYingwei/ShapeTextureDebiasedTraining","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"adversarial-robustness","task_name":"Adversarial Robustness"},{"task_slug":"data-augmentation","task_name":"Data Augmentation"},{"task_slug":"image-classification","task_name":"Image Classification"},{"task_slug":"representation-learning","task_name":"Representation Learning"}],"methods":[{"method_slug":"cutmix","method_name":"CutMix"},{"method_slug":"mixup","method_name":"Mixup"}],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/image-classification-on-imagenet","task":"Image Classification","dataset":"ImageNet","model":"ResNeXt-101 (Debiased+CutMix)","rank_in_archive_order":654,"of":1060,"metrics":{"Top 1 Accuracy":"81.2"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2010.05981","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2010.05981"}},"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/LiYingwei/ShapeTextureDebiasedTraining","reach":null}],"summary":{"ran":1,"unverified":3},"by_repo_kind":{"official":{"samples":4,"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":"437d92933ce78b3c","entry":"MixBatchNorm2d","repo":"LiYingwei/ShapeTextureDebiasedTraining","repo_kind":"official","path":"aux_bn.py","file_url":"https://github.com/LiYingwei/ShapeTextureDebiasedTraining/blob/HEAD/aux_bn.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"437d92933ce78b3c"}},{"code_sha256_prefix":"4b964e0652c2e423","entry":"resnext101","repo":"liyingwei/shapetexturedebiasedtraining","repo_kind":"official","path":"models/imagenet/resnext.py","file_url":"https://github.com/liyingwei/shapetexturedebiasedtraining/blob/HEAD/models/imagenet/resnext.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":"RAISES","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"4b964e0652c2e423"}},{"code_sha256_prefix":"e4aa8fed6f9728b7","entry":"resnext152","repo":"liyingwei/shapetexturedebiasedtraining","repo_kind":"official","path":"models/imagenet/resnext.py","file_url":"https://github.com/liyingwei/shapetexturedebiasedtraining/blob/HEAD/models/imagenet/resnext.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":"RAISES","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"e4aa8fed6f9728b7"}},{"code_sha256_prefix":"bd3747fe6948bc94","entry":"resnext50","repo":"liyingwei/shapetexturedebiasedtraining","repo_kind":"official","path":"models/imagenet/resnext.py","file_url":"https://github.com/liyingwei/shapetexturedebiasedtraining/blob/HEAD/models/imagenet/resnext.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":"RAISES","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"bd3747fe6948bc94"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}