{"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/a-low-shot-object-counting-network-with","title":"A Low-Shot Object Counting Network With Iterative Prototype Adaptation","arxiv_id":"2211.08217","date":"2022-11-15","proceeding":"ICCV 2023 1","authors":["Nikola Djukic","Alan Lukezic","Vitjan Zavrtanik","Matej Kristan"],"abstract":"We consider low-shot counting of arbitrary semantic categories in the image using only few annotated exemplars (few-shot) or no exemplars (no-shot). The standard few-shot pipeline follows extraction of appearance queries from exemplars and matching them with image features to infer the object counts. Existing methods extract queries by feature pooling which neglects the shape information (e.g., size and aspect) and leads to a reduced object localization accuracy and count estimates. We propose a Low-shot Object Counting network with iterative prototype Adaptation (LOCA). Our main contribution is the new object prototype extraction module, which iteratively fuses the exemplar shape and appearance information with image features. The module is easily adapted to zero-shot scenarios, enabling LOCA to cover the entire spectrum of low-shot counting problems. LOCA outperforms all recent state-of-the-art methods on FSC147 benchmark by 20-30% in RMSE on one-shot and few-shot and achieves state-of-the-art on zero-shot scenarios, while demonstrating better generalization capabilities.","url_abs":"https://arxiv.org/abs/2211.08217v2","url_pdf":"https://arxiv.org/pdf/2211.08217v2.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":"a-low-shot-object-counting-network-with","repo_url":"https://github.com/djukicn/loca","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"exemplar-free-counting","task_name":"Exemplar-Free Counting"},{"task_slug":"object","task_name":"Object"},{"task_slug":"object-counting","task_name":"Object Counting"},{"task_slug":"object-localization","task_name":"Object Localization"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/exemplar-free-counting-on-fsc147","task":"Exemplar-Free Counting","dataset":"FSC147","model":"LOCA","rank_in_archive_order":6,"of":9,"metrics":{"MAE(test)":"16.2","MAE(val)":"17.43","RMSE(test)":"103.96","RMSE(val)":"54.96"},"uses_additional_data":false},{"leaderboard":"/sota/object-counting-on-fsc147","task":"Object Counting","dataset":"FSC147","model":"LOCA","rank_in_archive_order":6,"of":19,"metrics":{"MAE(test)":"10.79","MAE(val)":"10.24","RMSE(test)":"56.97","RMSE(val)":"32.56"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2211.08217","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2211.08217"}},"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/djukicn/loca","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"unverified":2},"by_repo_kind":{"official":{"samples":2,"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":"53200053b02febbb","entry":"build_model","repo":"djukicn/loca","repo_kind":"official","path":"models/loca.py","file_url":"https://github.com/djukicn/loca/blob/HEAD/models/loca.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":"53200053b02febbb"}},{"code_sha256_prefix":"74ff2be7e10cc4d5","entry":"tiling_augmentation","repo":"djukicn/loca","repo_kind":"official","path":"utils/data.py","file_url":"https://github.com/djukicn/loca/blob/HEAD/utils/data.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":"74ff2be7e10cc4d5"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}