{"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/attention-branch-network-learning-of","title":"Attention Branch Network: Learning of Attention Mechanism for Visual Explanation","arxiv_id":"1812.10025","date":"2018-12-25","proceeding":"CVPR 2019 6","authors":["Hiroshi Fukui","Tsubasa Hirakawa","Takayoshi Yamashita","Hironobu Fujiyoshi"],"abstract":"Visual explanation enables human to understand the decision making of Deep\nConvolutional Neural Network (CNN), but it is insufficient to contribute the\nperformance improvement. In this paper, we focus on the attention map for\nvisual explanation, which represents high response value as the important\nregion in image recognition. This region significantly improves the performance\nof CNN by introducing an attention mechanism that focuses on a specific region\nin an image. In this work, we propose Attention Branch Network (ABN), which\nextends the top-down visual explanation model by introducing a branch structure\nwith an attention mechanism. ABN can be applicable to several image recognition\ntasks by introducing a branch for attention mechanism and is trainable for the\nvisual explanation and image recognition in end-to-end manner. We evaluate ABN\non several image recognition tasks such as image classification, fine-grained\nrecognition, and multiple facial attributes recognition. Experimental results\nshow that ABN can outperform the accuracy of baseline models on these image\nrecognition tasks while generating an attention map for visual explanation. Our\ncode is available at\nhttps://github.com/machine-perception-robotics-group/attention_branch_network.","url_abs":"http://arxiv.org/abs/1812.10025v2","url_pdf":"http://arxiv.org/pdf/1812.10025v2.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":"attention-branch-network-learning-of","repo_url":"https://github.com/machine-perception-robotics-group/attention_branch_network","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}},{"paper_slug":"attention-branch-network-learning-of","repo_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"none","reach":{"status":"ok"}},{"paper_slug":"attention-branch-network-learning-of","repo_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"decision-making","task_name":"Decision Making"},{"task_slug":"image-classification","task_name":"Image Classification"},{"task_slug":"image-classification","task_name":"image-classification"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=1812.10025","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"1812.10025"}},"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/machine-perception-robotics-group/ABN_CelebA","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/machine-perception-robotics-group/attention_branch_network","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"ran_draft_wrong":2,"unverified":22},"by_repo_kind":{"official":{"samples":10,"ran":2,"repositories":1},"listed":{"samples":14,"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":"fac5364e2f53c6db","entry":"conv3x3","repo":"machine-perception-robotics-group/attention_branch_network","repo_kind":"official","path":"models/cifar/resnet.py","file_url":"https://github.com/machine-perception-robotics-group/attention_branch_network/blob/HEAD/models/cifar/resnet.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":"50afa2863ffd9fde","entry":"plot_overlap","repo":"machine-perception-robotics-group/attention_branch_network","repo_kind":"official","path":"utils/logger.py","file_url":"https://github.com/machine-perception-robotics-group/attention_branch_network/blob/HEAD/utils/logger.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":"50afa2863ffd9fde"}},{"code_sha256_prefix":"47c2b42c776a53cb","entry":"binary_focal_loss_with_logits","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/nn/functional.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/nn/functional.py","link_basis":"harvester_set","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":"47c2b42c776a53cb"}},{"code_sha256_prefix":"c87e7665fde6cdfc","entry":"colorize","repo":"machine-perception-robotics-group/attention_branch_network","repo_kind":"official","path":"utils/visualize.py","file_url":"https://github.com/machine-perception-robotics-group/attention_branch_network/blob/HEAD/utils/visualize.py","link_basis":"harvester_set","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":"c87e7665fde6cdfc"}},{"code_sha256_prefix":"e720010f01055473","entry":"destandardize","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/attention.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/attention.py","link_basis":"harvester_set","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":"e720010f01055473"}},{"code_sha256_prefix":"d66f0a3cbb86204c","entry":"gauss","repo":"machine-perception-robotics-group/attention_branch_network","repo_kind":"official","path":"utils/visualize.py","file_url":"https://github.com/machine-perception-robotics-group/attention_branch_network/blob/HEAD/utils/visualize.py","link_basis":"harvester_set","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":"d66f0a3cbb86204c"}},{"code_sha256_prefix":"234594541416d949","entry":"get_celeba_frequency_histogram","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/datasets/celeba.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/datasets/celeba.py","link_basis":"harvester_set","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":"234594541416d949"}},{"code_sha256_prefix":"1d6e2edb8832d7b0","entry":"get_mean_and_std","repo":"machine-perception-robotics-group/attention_branch_network","repo_kind":"official","path":"utils/misc.py","file_url":"https://github.com/machine-perception-robotics-group/attention_branch_network/blob/HEAD/utils/misc.py","link_basis":"harvester_set","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":"1d6e2edb8832d7b0"}},{"code_sha256_prefix":"65829cf2917b3558","entry":"load_args","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/utils.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/utils.py","link_basis":"harvester_set","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":"65829cf2917b3558"}},{"code_sha256_prefix":"c7d8d95541a374e2","entry":"load_checkpoint","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/utils.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/utils.py","link_basis":"harvester_set","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":"c7d8d95541a374e2"}},{"code_sha256_prefix":"1394422d51c4b126","entry":"make_image","repo":"machine-perception-robotics-group/attention_branch_network","repo_kind":"official","path":"utils/visualize.py","file_url":"https://github.com/machine-perception-robotics-group/attention_branch_network/blob/HEAD/utils/visualize.py","link_basis":"harvester_set","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":"1394422d51c4b126"}},{"code_sha256_prefix":"6592afe32745dc44","entry":"mtabn_v1_resnet18","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/models/resnet_mtabn_v1.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/models/resnet_mtabn_v1.py","link_basis":"harvester_set","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":"6592afe32745dc44"}},{"code_sha256_prefix":"edc297b39164c0b0","entry":"mtabn_v1_resnet34","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/models/resnet_mtabn_v1.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/models/resnet_mtabn_v1.py","link_basis":"harvester_set","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":"edc297b39164c0b0"}},{"code_sha256_prefix":"18214b6aedae72b0","entry":"mtabn_v1_resnet50","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/models/resnet_mtabn_v1.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/models/resnet_mtabn_v1.py","link_basis":"harvester_set","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":"18214b6aedae72b0"}},{"code_sha256_prefix":"cfb9271275aaa4a0","entry":"mtabn_v2_resnet18","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/models/resnet_mtabn_v2.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/models/resnet_mtabn_v2.py","link_basis":"harvester_set","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":"cfb9271275aaa4a0"}},{"code_sha256_prefix":"75ac9db68ee7f5ec","entry":"mtabn_v2_resnet34","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/models/resnet_mtabn_v2.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/models/resnet_mtabn_v2.py","link_basis":"harvester_set","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":"75ac9db68ee7f5ec"}},{"code_sha256_prefix":"aeb1f09ac10440c0","entry":"mtabn_v2_resnet50","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/models/resnet_mtabn_v2.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/models/resnet_mtabn_v2.py","link_basis":"harvester_set","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":"aeb1f09ac10440c0"}},{"code_sha256_prefix":"bcc372d89673d501","entry":"normalize","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/attention.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/attention.py","link_basis":"harvester_set","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":"bcc372d89673d501"}},{"code_sha256_prefix":"da0371a734c15317","entry":"normalize_pos_neg","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/attention.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/attention.py","link_basis":"harvester_set","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":"da0371a734c15317"}},{"code_sha256_prefix":"ac0a3fc9f67b5838","entry":"resnet18","repo":"machine-perception-robotics-group/attention_branch_network","repo_kind":"official","path":"models/imagenet/resnet.py","file_url":"https://github.com/machine-perception-robotics-group/attention_branch_network/blob/HEAD/models/imagenet/resnet.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":"ac0a3fc9f67b5838"}},{"code_sha256_prefix":"38fb052bcacc8fd4","entry":"resnet34","repo":"machine-perception-robotics-group/attention_branch_network","repo_kind":"official","path":"models/imagenet/resnet.py","file_url":"https://github.com/machine-perception-robotics-group/attention_branch_network/blob/HEAD/models/imagenet/resnet.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":"38fb052bcacc8fd4"}},{"code_sha256_prefix":"0743eaa7c20d2dcd","entry":"se_resnet_18","repo":"machine-perception-robotics-group/attention_branch_network","repo_kind":"official","path":"models/imagenet/senet_resnet.py","file_url":"https://github.com/machine-perception-robotics-group/attention_branch_network/blob/HEAD/models/imagenet/senet_resnet.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":"0743eaa7c20d2dcd"}},{"code_sha256_prefix":"a2e7b01d49ea2d31","entry":"se_resnet_34","repo":"machine-perception-robotics-group/attention_branch_network","repo_kind":"official","path":"models/imagenet/senet_resnet.py","file_url":"https://github.com/machine-perception-robotics-group/attention_branch_network/blob/HEAD/models/imagenet/senet_resnet.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":"a2e7b01d49ea2d31"}},{"code_sha256_prefix":"923b2c3bc7b852da","entry":"weighted_binary_focal_loss_with_logits","repo":"machine-perception-robotics-group/ABN_CelebA_PyTorch","repo_kind":"listed","path":"mtabn/nn/functional.py","file_url":"https://github.com/machine-perception-robotics-group/ABN_CelebA_PyTorch/blob/HEAD/mtabn/nn/functional.py","link_basis":"harvester_set","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":"923b2c3bc7b852da"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}