{"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/hyperdomainnet-universal-domain-adaptation","title":"HyperDomainNet: Universal Domain Adaptation for Generative Adversarial Networks","arxiv_id":"2210.08884","date":"2022-10-17","proceeding":null,"authors":["Aibek Alanov","Vadim Titov","Dmitry Vetrov"],"abstract":"Domain adaptation framework of GANs has achieved great progress in recent years as a main successful approach of training contemporary GANs in the case of very limited training data. In this work, we significantly improve this framework by proposing an extremely compact parameter space for fine-tuning the generator. We introduce a novel domain-modulation technique that allows to optimize only 6 thousand-dimensional vector instead of 30 million weights of StyleGAN2 to adapt to a target domain. We apply this parameterization to the state-of-art domain adaptation methods and show that it has almost the same expressiveness as the full parameter space. Additionally, we propose a new regularization loss that considerably enhances the diversity of the fine-tuned generator. Inspired by the reduction in the size of the optimizing parameter space we consider the problem of multi-domain adaptation of GANs, i.e. setting when the same model can adapt to several domains depending on the input query. We propose the HyperDomainNet that is a hypernetwork that predicts our parameterization given the target domain. We empirically confirm that it can successfully learn a number of domains at once and may even generalize to unseen domains. Source code can be found at https://github.com/MACderRu/HyperDomainNet","url_abs":"https://arxiv.org/abs/2210.08884v4","url_pdf":"https://arxiv.org/pdf/2210.08884v4.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":"hyperdomainnet-universal-domain-adaptation","repo_url":"https://github.com/macderru/hyperdomainnet","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"domain-adaptation","task_name":"Domain Adaptation"},{"task_slug":"universal-domain-adaptation","task_name":"Universal Domain Adaptation"}],"methods":[{"method_slug":"convolution","method_name":"Convolution"},{"method_slug":"hypernetwork","method_name":"HyperNetwork"},{"method_slug":"path-length-regularization","method_name":"Path Length Regularization"},{"method_slug":"r1-regularization","method_name":"R1 Regularization"},{"method_slug":"weight-demodulation","method_name":"Weight Demodulation"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2210.08884","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2210.08884"}},"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/macderru/hyperdomainnet","reach":null}],"summary":{"ran":5,"ran_fixture":1,"ran_honours":1,"ran_draft_wrong":1,"unverified":8},"by_repo_kind":{"official":{"samples":16,"ran":8,"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":"0b20639615622596","entry":"Blur","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.py","link_basis":"first_harvest_node","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":"0b20639615622596"}},{"code_sha256_prefix":"1601948f4ac658fc","entry":"ClassRegistry","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.py","link_basis":"first_harvest_node","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":"1601948f4ac658fc"}},{"code_sha256_prefix":"78c0c8d1ea4d6eb6","entry":"EqualLinear","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.py","link_basis":"first_harvest_node","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":"78c0c8d1ea4d6eb6"}},{"code_sha256_prefix":"15c6d8b415268285","entry":"ModulatedConv2d","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.py","link_basis":"first_harvest_node","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":"15c6d8b415268285"}},{"code_sha256_prefix":"5845b86e0c4d496d","entry":"Upsample","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.py","link_basis":"first_harvest_node","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":"5845b86e0c4d496d"}},{"code_sha256_prefix":"32adb2d122679599","entry":"get_avg_image","repo":"MACderRu/HyperDomainNet","repo_kind":"official","path":"core/utils/example_utils.py","file_url":"https://github.com/MACderRu/HyperDomainNet/blob/HEAD/core/utils/example_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"32adb2d122679599"}},{"code_sha256_prefix":"6055f06158ae1524","entry":"load_latent","repo":"MACderRu/HyperDomainNet","repo_kind":"official","path":"core/utils/example_utils.py","file_url":"https://github.com/MACderRu/HyperDomainNet/blob/HEAD/core/utils/example_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":"well_formed","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"6055f06158ae1524"}},{"code_sha256_prefix":"b759cb2df53ad9a8","entry":"run_on_batch","repo":"MACderRu/HyperDomainNet","repo_kind":"official","path":"core/utils/example_utils.py","file_url":"https://github.com/MACderRu/HyperDomainNet/blob/HEAD/core/utils/example_utils.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"b759cb2df53ad9a8"}},{"code_sha256_prefix":"17d45a0afbc836f2","entry":"DecModulatedConv2d","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.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":"17d45a0afbc836f2"}},{"code_sha256_prefix":"e9718036937d874b","entry":"ModModulatedConv2d","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.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":"e9718036937d874b"}},{"code_sha256_prefix":"223ac0755039f519","entry":"OffsetsGenerator","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.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":"223ac0755039f519"}},{"code_sha256_prefix":"6e8bab058d83a17c","entry":"OffsetsStyledConv","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.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":"6e8bab058d83a17c"}},{"code_sha256_prefix":"39c0a83a746f7304","entry":"OffsetsTunningGenerator","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.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":"39c0a83a746f7304"}},{"code_sha256_prefix":"01421864e3adfd3c","entry":"StyleModulatedConv2d","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.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":"01421864e3adfd3c"}},{"code_sha256_prefix":"a3e38a9052507399","entry":"ToRGB","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.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":"a3e38a9052507399"}},{"code_sha256_prefix":"cee6bfbe557ea802","entry":"requires_grad","repo":"macderru/hyperdomainnet","repo_kind":"official","path":"core/uda_models.py","file_url":"https://github.com/macderru/hyperdomainnet/blob/HEAD/core/uda_models.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":"cee6bfbe557ea802"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}