{"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/cross-domain-few-shot-classification-via-1","title":"Cross-Domain Few-Shot Classification via Learned Feature-Wise Transformation","arxiv_id":"2001.08735","date":"2020-01-23","proceeding":"ICLR 2020 1","authors":["Hung-Yu Tseng","Hsin-Ying Lee","Jia-Bin Huang","Ming-Hsuan Yang"],"abstract":"Few-shot classification aims to recognize novel categories with only few labeled images in each class. Existing metric-based few-shot classification algorithms predict categories by comparing the feature embeddings of query images with those from a few labeled images (support examples) using a learned metric function. While promising performance has been demonstrated, these methods often fail to generalize to unseen domains due to large discrepancy of the feature distribution across domains. In this work, we address the problem of few-shot classification under domain shifts for metric-based methods. Our core idea is to use feature-wise transformation layers for augmenting the image features using affine transforms to simulate various feature distributions under different domains in the training stage. To capture variations of the feature distributions under different domains, we further apply a learning-to-learn approach to search for the hyper-parameters of the feature-wise transformation layers. We conduct extensive experiments and ablation studies under the domain generalization setting using five few-shot classification datasets: mini-ImageNet, CUB, Cars, Places, and Plantae. Experimental results demonstrate that the proposed feature-wise transformation layer is applicable to various metric-based models, and provides consistent improvements on the few-shot classification performance under domain shift.","url_abs":"https://arxiv.org/abs/2001.08735v3","url_pdf":"https://arxiv.org/pdf/2001.08735v3.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":"cross-domain-few-shot-classification-via-1","repo_url":"https://github.com/hytseng0509/CrossDomainFewShot","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"classification-1","task_name":"Classification"},{"task_slug":"cross-domain-few-shot","task_name":"Cross-Domain Few-Shot"},{"task_slug":"domain-generalization","task_name":"Domain Generalization"},{"task_slug":"classification","task_name":"General Classification"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/cross-domain-few-shot-on-cub","task":"Cross-Domain Few-Shot","dataset":"CUB","model":"FWT","rank_in_archive_order":7,"of":9,"metrics":{"5 shot":"66.98"},"uses_additional_data":false},{"leaderboard":"/sota/cross-domain-few-shot-on-chestx","task":"Cross-Domain Few-Shot","dataset":"ChestX","model":"FWT","rank_in_archive_order":7,"of":11,"metrics":{"5 shot":"25.18"},"uses_additional_data":false},{"leaderboard":"/sota/cross-domain-few-shot-on-cropdisease","task":"Cross-Domain Few-Shot","dataset":"CropDisease","model":"FWT","rank_in_archive_order":9,"of":9,"metrics":{"5 shot":"87.11"},"uses_additional_data":false},{"leaderboard":"/sota/cross-domain-few-shot-on-eurosat","task":"Cross-Domain Few-Shot","dataset":"EuroSAT","model":"FWT","rank_in_archive_order":8,"of":11,"metrics":{"5 shot":"83.01"},"uses_additional_data":false},{"leaderboard":"/sota/cross-domain-few-shot-on-isic2018","task":"Cross-Domain Few-Shot","dataset":"ISIC2018","model":"FWT","rank_in_archive_order":11,"of":11,"metrics":{"5 shot":"43.17"},"uses_additional_data":false},{"leaderboard":"/sota/cross-domain-few-shot-on-places","task":"Cross-Domain Few-Shot","dataset":"Places","model":"FWT","rank_in_archive_order":7,"of":8,"metrics":{"5 shot":"73.94"},"uses_additional_data":false},{"leaderboard":"/sota/cross-domain-few-shot-on-plantae","task":"Cross-Domain Few-Shot","dataset":"Plantae","model":"FWT","rank_in_archive_order":7,"of":8,"metrics":{"5 shot":"53.85"},"uses_additional_data":false},{"leaderboard":"/sota/cross-domain-few-shot-on-cars","task":"Cross-Domain Few-Shot","dataset":"cars","model":"FWT","rank_in_archive_order":8,"of":8,"metrics":{"5 shot":"44.90"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2001.08735","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2001.08735"}},"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/hytseng0509/CrossDomainFewShot","reach":null}],"summary":{"ran":1,"ran_draft_wrong":1},"by_repo_kind":{"official":{"samples":2,"ran":2,"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":2,"samples":[{"code_sha256_prefix":"1b6f2d574f8aa3bc","entry":"FeatureWiseTransformation2d_fw","repo":"hytseng0509/CrossDomainFewShot","repo_kind":"official","path":"methods/backbone.py","file_url":"https://github.com/hytseng0509/CrossDomainFewShot/blob/HEAD/methods/backbone.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"1b6f2d574f8aa3bc"}},{"code_sha256_prefix":"938085d32a386023","entry":"softplus","repo":"hytseng0509/CrossDomainFewShot","repo_kind":"official","path":"methods/backbone.py","file_url":"https://github.com/hytseng0509/CrossDomainFewShot/blob/HEAD/methods/backbone.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"938085d32a386023"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}