{"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/incremental-few-shot-learning-with-attention","title":"Incremental Few-Shot Learning with Attention Attractor Networks","arxiv_id":"1810.07218","date":"2018-10-16","proceeding":"NeurIPS 2019 12","authors":["Mengye Ren","Renjie Liao","Ethan Fetaya","Richard S. Zemel"],"abstract":"Machine learning classifiers are often trained to recognize a set of pre-defined classes. However, in many applications, it is often desirable to have the flexibility of learning additional concepts, with limited data and without re-training on the full training set. This paper addresses this problem, incremental few-shot learning, where a regular classification network has already been trained to recognize a set of base classes, and several extra novel classes are being considered, each with only a few labeled examples. After learning the novel classes, the model is then evaluated on the overall classification performance on both base and novel classes. To this end, we propose a meta-learning model, the Attention Attractor Network, which regularizes the learning of novel classes. In each episode, we train a set of new weights to recognize novel classes until they converge, and we show that the technique of recurrent back-propagation can back-propagate through the optimization process and facilitate the learning of these parameters. We demonstrate that the learned attractor network can help recognize novel classes while remembering old classes without the need to review the original training set, outperforming various baselines.","url_abs":"https://arxiv.org/abs/1810.07218v3","url_pdf":"https://arxiv.org/pdf/1810.07218v3.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":"incremental-few-shot-learning-with-attention","repo_url":"https://github.com/renmengye/inc-few-shot-attractor-public","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"tf","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"few-shot-learning","task_name":"Few-Shot Learning"},{"task_slug":"classification","task_name":"General Classification"},{"task_slug":"meta-learning","task_name":"Meta-Learning"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=1810.07218","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"1810.07218"}},"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/renmengye/inc-few-shot-attractor-public","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"unverified":10},"by_repo_kind":{"official":{"samples":10,"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":"db1395e0b1c22f55","entry":"RegisterAttractor","repo":"renmengye/inc-few-shot-attractor-public","repo_kind":"official","path":"fewshot/models/attractors/attractor.py","file_url":"https://github.com/renmengye/inc-few-shot-attractor-public/blob/HEAD/fewshot/models/attractors/attractor.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":"db1395e0b1c22f55"}},{"code_sha256_prefix":"fd146e231aa1f310","entry":"assign_cluster","repo":"renmengye/inc-few-shot-attractor-public","repo_kind":"official","path":"fewshot/models/kmeans_utils.py","file_url":"https://github.com/renmengye/inc-few-shot-attractor-public/blob/HEAD/fewshot/models/kmeans_utils.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":"fd146e231aa1f310"}},{"code_sha256_prefix":"9c0f25b4ea59ecb4","entry":"calculate_episode_protos","repo":"renmengye/inc-few-shot-attractor-public","repo_kind":"official","path":"run_proto_exp.py","file_url":"https://github.com/renmengye/inc-few-shot-attractor-public/blob/HEAD/run_proto_exp.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":"9c0f25b4ea59ecb4"}},{"code_sha256_prefix":"03c9fac0501311a0","entry":"calculate_protos","repo":"renmengye/inc-few-shot-attractor-public","repo_kind":"official","path":"run_proto_exp.py","file_url":"https://github.com/renmengye/inc-few-shot-attractor-public/blob/HEAD/run_proto_exp.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":"03c9fac0501311a0"}},{"code_sha256_prefix":"b4b89c2bb9f5f4f1","entry":"compute_logits","repo":"renmengye/inc-few-shot-attractor-public","repo_kind":"official","path":"fewshot/models/kmeans_utils.py","file_url":"https://github.com/renmengye/inc-few-shot-attractor-public/blob/HEAD/fewshot/models/kmeans_utils.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":"b4b89c2bb9f5f4f1"}},{"code_sha256_prefix":"003314f3ea6c637c","entry":"compute_logits_cosine","repo":"renmengye/inc-few-shot-attractor-public","repo_kind":"official","path":"fewshot/models/kmeans_utils.py","file_url":"https://github.com/renmengye/inc-few-shot-attractor-public/blob/HEAD/fewshot/models/kmeans_utils.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":"003314f3ea6c637c"}},{"code_sha256_prefix":"4dedc68d854ae87b","entry":"cosine","repo":"renmengye/inc-few-shot-attractor-public","repo_kind":"official","path":"run_proto_exp.py","file_url":"https://github.com/renmengye/inc-few-shot-attractor-public/blob/HEAD/run_proto_exp.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":"4dedc68d854ae87b"}},{"code_sha256_prefix":"3a411d462f300aee","entry":"get_attractor","repo":"renmengye/inc-few-shot-attractor-public","repo_kind":"official","path":"fewshot/models/attractors/attractor.py","file_url":"https://github.com/renmengye/inc-few-shot-attractor-public/blob/HEAD/fewshot/models/attractors/attractor.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":"3a411d462f300aee"}},{"code_sha256_prefix":"cf5426582b207c79","entry":"get_exp_logger","repo":"renmengye/inc-few-shot-attractor-public","repo_kind":"official","path":"run_exp.py","file_url":"https://github.com/renmengye/inc-few-shot-attractor-public/blob/HEAD/run_exp.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":"cf5426582b207c79"}},{"code_sha256_prefix":"d289bd846920809c","entry":"get_saver","repo":"renmengye/inc-few-shot-attractor-public","repo_kind":"official","path":"run_exp.py","file_url":"https://github.com/renmengye/inc-few-shot-attractor-public/blob/HEAD/run_exp.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":"d289bd846920809c"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}