{"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/domain-adaptation-under-open-set-label-shift","title":"Domain Adaptation under Open Set Label Shift","arxiv_id":"2207.13048","date":"2022-07-26","proceeding":null,"authors":["Saurabh Garg","Sivaraman Balakrishnan","Zachary C. Lipton"],"abstract":"We introduce the problem of domain adaptation under Open Set Label Shift (OSLS) where the label distribution can change arbitrarily and a new class may arrive during deployment, but the class-conditional distributions p(x|y) are domain-invariant. OSLS subsumes domain adaptation under label shift and Positive-Unlabeled (PU) learning. The learner's goals here are two-fold: (a) estimate the target label distribution, including the novel class; and (b) learn a target classifier. First, we establish necessary and sufficient conditions for identifying these quantities. Second, motivated by advances in label shift and PU learning, we propose practical methods for both tasks that leverage black-box predictors. Unlike typical Open Set Domain Adaptation (OSDA) problems, which tend to be ill-posed and amenable only to heuristics, OSLS offers a well-posed problem amenable to more principled machinery. Experiments across numerous semi-synthetic benchmarks on vision, language, and medical datasets demonstrate that our methods consistently outperform OSDA baselines, achieving 10--25% improvements in target domain accuracy. Finally, we analyze the proposed methods, establishing finite-sample convergence to the true label marginal and convergence to optimal classifier for linear models in a Gaussian setup. Code is available at https://github.com/acmi-lab/Open-Set-Label-Shift.","url_abs":"https://arxiv.org/abs/2207.13048v2","url_pdf":"https://arxiv.org/pdf/2207.13048v2.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":"domain-adaptation-under-open-set-label-shift","repo_url":"https://github.com/acmi-lab/open-set-label-shift","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"Apache-2.0"}}],"tasks":[{"task_slug":"domain-adaptation","task_name":"Domain Adaptation"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2207.13048","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2207.13048"}},"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":"deterministic:regex_extraction","url":"https://github.com/VisionLearningGroup/DANCE","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/acmi-lab/open-set-label-shift","reach":{"status":"ok","spdx":"Apache-2.0"}}],"summary":{"ran":2,"ran_draft_wrong":1,"ran_violates":1,"unverified":22},"by_repo_kind":{"official":{"samples":12,"ran":1,"repositories":1},"found_in_text":{"samples":14,"ran":3,"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":"e4361b7969382ced","entry":"DKW_bound","repo":"acmi-lab/open-set-label-shift","repo_kind":"official","path":"src/core_utils.py","file_url":"https://github.com/acmi-lab/open-set-label-shift/blob/HEAD/src/core_utils.py","link_basis":"harvester_set","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"e4361b7969382ced"}},{"code_sha256_prefix":"fac5364e2f53c6db","entry":"conv3x3","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"models/resnet.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/models/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":"52d10a10fb72fb9f","entry":"find_classes","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"data_loader/mydataset.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/data_loader/mydataset.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":"52d10a10fb72fb9f"}},{"code_sha256_prefix":"ab4109634b75ef8b","entry":"is_image_file","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"data_loader/mydataset.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/data_loader/mydataset.py","link_basis":"harvester_set","language":"python","status":"ran_violates","verification_level":1,"contract_check":"VIOLATES","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"ab4109634b75ef8b"}},{"code_sha256_prefix":"14e37cf982988836","entry":"DenseNet121","repo":"acmi-lab/open-set-label-shift","repo_kind":"official","path":"models/Densenet.py","file_url":"https://github.com/acmi-lab/open-set-label-shift/blob/HEAD/models/Densenet.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"14e37cf982988836"}},{"code_sha256_prefix":"b3ac43769fb04b47","entry":"DenseNet169","repo":"acmi-lab/open-set-label-shift","repo_kind":"official","path":"models/Densenet.py","file_url":"https://github.com/acmi-lab/open-set-label-shift/blob/HEAD/models/Densenet.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"b3ac43769fb04b47"}},{"code_sha256_prefix":"2b9e6d4a74c359a6","entry":"DenseNet201","repo":"acmi-lab/open-set-label-shift","repo_kind":"official","path":"models/Densenet.py","file_url":"https://github.com/acmi-lab/open-set-label-shift/blob/HEAD/models/Densenet.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"2b9e6d4a74c359a6"}},{"code_sha256_prefix":"6fad1b656bc73c83","entry":"ResNet18","repo":"acmi-lab/open-set-label-shift","repo_kind":"official","path":"models/Resnet.py","file_url":"https://github.com/acmi-lab/open-set-label-shift/blob/HEAD/models/Resnet.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"6fad1b656bc73c83"}},{"code_sha256_prefix":"448400e6aad91289","entry":"ResNet34","repo":"acmi-lab/open-set-label-shift","repo_kind":"official","path":"models/Resnet.py","file_url":"https://github.com/acmi-lab/open-set-label-shift/blob/HEAD/models/Resnet.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"448400e6aad91289"}},{"code_sha256_prefix":"d8e384423a8b2d0d","entry":"ResNet50","repo":"acmi-lab/open-set-label-shift","repo_kind":"official","path":"models/Resnet.py","file_url":"https://github.com/acmi-lab/open-set-label-shift/blob/HEAD/models/Resnet.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"d8e384423a8b2d0d"}},{"code_sha256_prefix":"69730b3058d667fa","entry":"dataset_with_indices","repo":"acmi-lab/open-set-label-shift","repo_kind":"official","path":"src/data_utils.py","file_url":"https://github.com/acmi-lab/open-set-label-shift/blob/HEAD/src/data_utils.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"69730b3058d667fa"}},{"code_sha256_prefix":"28cffa65eceff97d","entry":"entropy","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"utils/loss.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/utils/loss.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":"28cffa65eceff97d"}},{"code_sha256_prefix":"fbced886c2390bd6","entry":"entropy_margin","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"utils/loss.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/utils/loss.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":"fbced886c2390bd6"}},{"code_sha256_prefix":"e5f7f1545b01669a","entry":"get_label_dist","repo":"acmi-lab/open-set-label-shift","repo_kind":"official","path":"src/core_utils.py","file_url":"https://github.com/acmi-lab/open-set-label-shift/blob/HEAD/src/core_utils.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"e5f7f1545b01669a"}},{"code_sha256_prefix":"32da59e81223a5d4","entry":"get_labels","repo":"acmi-lab/open-set-label-shift","repo_kind":"official","path":"src/data_utils.py","file_url":"https://github.com/acmi-lab/open-set-label-shift/blob/HEAD/src/data_utils.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"32da59e81223a5d4"}},{"code_sha256_prefix":"01528e3c98ec363f","entry":"get_loader","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"data_loader/get_loader.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/data_loader/get_loader.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":"01528e3c98ec363f"}},{"code_sha256_prefix":"d73084d59289922d","entry":"get_loader_balanced","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"data_loader/get_loader.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/data_loader/get_loader.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":"d73084d59289922d"}},{"code_sha256_prefix":"2e567fd759bd44d6","entry":"get_loader_class_inc","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"data_loader/get_loader.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/data_loader/get_loader.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":"2e567fd759bd44d6"}},{"code_sha256_prefix":"1488363eb47eebb8","entry":"get_size_per_class","repo":"acmi-lab/open-set-label-shift","repo_kind":"official","path":"src/data_utils.py","file_url":"https://github.com/acmi-lab/open-set-label-shift/blob/HEAD/src/data_utils.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"1488363eb47eebb8"}},{"code_sha256_prefix":"0822c90f53494f2e","entry":"grad_reverse","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"models/basenet.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/models/basenet.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":"0822c90f53494f2e"}},{"code_sha256_prefix":"f0d7f006856a6a6b","entry":"hinge","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"utils/loss.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/utils/loss.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":"f0d7f006856a6a6b"}},{"code_sha256_prefix":"8395d539bd4cf136","entry":"inv_lr_scheduler","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"utils/lr_schedule.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/utils/lr_schedule.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":"8395d539bd4cf136"}},{"code_sha256_prefix":"d90e54cc28eb9dba","entry":"make_dataset","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"data_loader/mydataset.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/data_loader/mydataset.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":"d90e54cc28eb9dba"}},{"code_sha256_prefix":"f320a100b322580c","entry":"resnet18","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"models/resnet.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/models/resnet.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":"f320a100b322580c"}},{"code_sha256_prefix":"e8b58c55eb274d6a","entry":"resnet50","repo":"VisionLearningGroup/DANCE","repo_kind":"found_in_text","path":"models/resnet.py","file_url":"https://github.com/VisionLearningGroup/DANCE/blob/HEAD/models/resnet.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":"e8b58c55eb274d6a"}},{"code_sha256_prefix":"4dd7d1ab34f2c834","entry":"top_bin_estimator","repo":"acmi-lab/open-set-label-shift","repo_kind":"official","path":"src/core_utils.py","file_url":"https://github.com/acmi-lab/open-set-label-shift/blob/HEAD/src/core_utils.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"4dd7d1ab34f2c834"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}