{"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/few-shot-object-detection-with-attention-rpn","title":"Few-Shot Object Detection with Attention-RPN and Multi-Relation Detector","arxiv_id":"1908.01998","date":"2019-08-06","proceeding":"CVPR 2020 6","authors":["Qi Fan","Wei Zhuo","Chi-Keung Tang","Yu-Wing Tai"],"abstract":"Conventional methods for object detection typically require a substantial amount of training data and preparing such high-quality training data is very labor-intensive. In this paper, we propose a novel few-shot object detection network that aims at detecting objects of unseen categories with only a few annotated examples. Central to our method are our Attention-RPN, Multi-Relation Detector and Contrastive Training strategy, which exploit the similarity between the few shot support set and query set to detect novel objects while suppressing false detection in the background. To train our network, we contribute a new dataset that contains 1000 categories of various objects with high-quality annotations. To the best of our knowledge, this is one of the first datasets specifically designed for few-shot object detection. Once our few-shot network is trained, it can detect objects of unseen categories without further training or fine-tuning. Our method is general and has a wide range of potential applications. We produce a new state-of-the-art performance on different datasets in the few-shot setting. The dataset link is https://github.com/fanq15/Few-Shot-Object-Detection-Dataset.","url_abs":"https://arxiv.org/abs/1908.01998v4","url_pdf":"https://arxiv.org/pdf/1908.01998v4.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":"few-shot-object-detection-with-attention-rpn","repo_url":"https://github.com/fanq15/FewX","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}},{"paper_slug":"few-shot-object-detection-with-attention-rpn","repo_url":"https://github.com/fanq15/Few-Shot-Object-Detection-Dataset","is_official":0,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"none","reach":{"status":"ok"}},{"paper_slug":"few-shot-object-detection-with-attention-rpn","repo_url":"https://github.com/fanq15/FSOD-code","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"few-shot-object-detection","task_name":"Few-Shot Object Detection"},{"task_slug":"object","task_name":"Object"},{"task_slug":"object-detection","task_name":"Object Detection"},{"task_slug":null,"task_name":"Relation"},{"task_slug":"object-detection-1","task_name":"object-detection"}],"methods":[],"datasets_introduced":[{"slug":"fsod","name":"FSOD","full_name":"Few-Shot Object Detection Dataset"}],"methods_introduced":[],"results":[{"leaderboard":"/sota/few-shot-object-detection-on-ms-coco-10-shot","task":"Few-Shot Object Detection","dataset":"MS-COCO (10-shot)","model":"FSOD","rank_in_archive_order":24,"of":33,"metrics":{"AP":"11.1"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=1908.01998","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"1908.01998"}},"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/fanq15/FewX","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/fanq15/FSOD-code","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/fanq15/Few-Shot-Object-Detection-Dataset","reach":{"status":"ok"}}],"summary":{"ran":2,"unverified":8},"by_repo_kind":{"official":{"samples":4,"ran":2,"repositories":1},"listed":{"samples":6,"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":"37048c236eb86341","entry":"get_contour_interior","repo":"fanq15/FewX","repo_kind":"official","path":"fewx/layers/boundary.py","file_url":"https://github.com/fanq15/FewX/blob/HEAD/fewx/layers/boundary.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"37048c236eb86341"}},{"code_sha256_prefix":"9b506f9da113b9eb","entry":"get_instances_contour_interior","repo":"fanq15/FewX","repo_kind":"official","path":"fewx/layers/boundary.py","file_url":"https://github.com/fanq15/FewX/blob/HEAD/fewx/layers/boundary.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"9b506f9da113b9eb"}},{"code_sha256_prefix":"38bddb8fee66fd8b","entry":"get_box_cls_ls","repo":"fanq15/FSOD-code","repo_kind":"listed","path":"lib/3_pred_gt_sim_det_fast.py","file_url":"https://github.com/fanq15/FSOD-code/blob/HEAD/lib/3_pred_gt_sim_det_fast.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":"38bddb8fee66fd8b"}},{"code_sha256_prefix":"dac8413f65a84dfc","entry":"get_center","repo":"fanq15/FewX","repo_kind":"official","path":"fewx/layers/boundary.py","file_url":"https://github.com/fanq15/FewX/blob/HEAD/fewx/layers/boundary.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":"dac8413f65a84dfc"}},{"code_sha256_prefix":"c3b291d046f1622d","entry":"get_pkl_ls","repo":"fanq15/FSOD-code","repo_kind":"listed","path":"lib/3_pred_gt_sim_det_fast.py","file_url":"https://github.com/fanq15/FSOD-code/blob/HEAD/lib/3_pred_gt_sim_det_fast.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":"c3b291d046f1622d"}},{"code_sha256_prefix":"2902bf4410253ff7","entry":"interpolate","repo":"fanq15/FewX","repo_kind":"official","path":"fewx/layers/misc.py","file_url":"https://github.com/fanq15/FewX/blob/HEAD/fewx/layers/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":"2902bf4410253ff7"}},{"code_sha256_prefix":"06e62194f17cd06a","entry":"parse_rec","repo":"fanq15/FSOD-code","repo_kind":"listed","path":"lib/datasets/voc_eval.py","file_url":"https://github.com/fanq15/FSOD-code/blob/HEAD/lib/datasets/voc_eval.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":"06e62194f17cd06a"}},{"code_sha256_prefix":"611c47c44c424dba","entry":"voc_ap","repo":"fanq15/FSOD-code","repo_kind":"listed","path":"lib/datasets/voc_eval.py","file_url":"https://github.com/fanq15/FSOD-code/blob/HEAD/lib/datasets/voc_eval.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":"611c47c44c424dba"}},{"code_sha256_prefix":"f7e098820789174a","entry":"voc_ap","repo":"fanq15/FSOD-code","repo_kind":"listed","path":"lib/3_pred_gt_sim_det_fast.py","file_url":"https://github.com/fanq15/FSOD-code/blob/HEAD/lib/3_pred_gt_sim_det_fast.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":"f7e098820789174a"}},{"code_sha256_prefix":"fa2ad31f1f9213e1","entry":"voc_eval","repo":"fanq15/FSOD-code","repo_kind":"listed","path":"lib/datasets/voc_eval.py","file_url":"https://github.com/fanq15/FSOD-code/blob/HEAD/lib/datasets/voc_eval.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":"fa2ad31f1f9213e1"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}