{"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/moreau-yosida-f-divergences","title":"Moreau-Yosida $f$-divergences","arxiv_id":"2102.13416","date":"2021-02-26","proceeding":null,"authors":["Dávid Terjék"],"abstract":"Variational representations of $f$-divergences are central to many machine learning algorithms, with Lipschitz constrained variants recently gaining attention. Inspired by this, we define the Moreau-Yosida approximation of $f$-divergences with respect to the Wasserstein-$1$ metric. The corresponding variational formulas provide a generalization of a number of recent results, novel special cases of interest and a relaxation of the hard Lipschitz constraint. Additionally, we prove that the so-called tight variational representation of $f$-divergences can be to be taken over the quotient space of Lipschitz functions, and give a characterization of functions achieving the supremum in the variational representation. On the practical side, we propose an algorithm to calculate the tight convex conjugate of $f$-divergences compatible with automatic differentiation frameworks. As an application of our results, we propose the Moreau-Yosida $f$-GAN, providing an implementation of the variational formulas for the Kullback-Leibler, reverse Kullback-Leibler, $\\chi^2$, reverse $\\chi^2$, squared Hellinger, Jensen-Shannon, Jeffreys, triangular discrimination and total variation divergences as GANs trained on CIFAR-10, leading to competitive results and a simple solution to the problem of uniqueness of the optimal critic.","url_abs":"https://arxiv.org/abs/2102.13416v2","url_pdf":"https://arxiv.org/pdf/2102.13416v2.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":"moreau-yosida-f-divergences","repo_url":"https://github.com/renyi-ai/moreau-yosida-f-divergences","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"tf","reach":null}],"tasks":[],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":"https://syntology.ai/paper/2102.13416","atlas_url":"https://app.syntology.ai/?focus=2102.13416","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2102.13416"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-25T09:33:49+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/jackd/lambertw","reach":{"status":"unanswered"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/renyi-ai/moreau-yosida-f-divergences","reach":null}],"summary":{"ran_violates":1,"ran_draft_wrong":2,"unverified":1},"by_repo_kind":{"official":{"samples":4,"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":4,"samples":[{"code_sha256_prefix":"bebed26fa76ed602","entry":"gamma_reverse_kl","repo":"renyi-ai/moreau-yosida-f-divergences","repo_kind":"official","path":"gan_cifar10.py","file_url":"https://github.com/renyi-ai/moreau-yosida-f-divergences/blob/HEAD/gan_cifar10.py","link_basis":"first_harvest_node","language":"python","status":"ran_violates","verification_level":1,"contract_check":"VIOLATES","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"bebed26fa76ed602"}},{"code_sha256_prefix":"257839deea092962","entry":"get_cifar10_dataset","repo":"renyi-ai/moreau-yosida-f-divergences","repo_kind":"official","path":"gan_cifar10.py","file_url":"https://github.com/renyi-ai/moreau-yosida-f-divergences/blob/HEAD/gan_cifar10.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"257839deea092962"}},{"code_sha256_prefix":"c41924e881d94c2e","entry":"unpickle","repo":"renyi-ai/moreau-yosida-f-divergences","repo_kind":"official","path":"gan_cifar10.py","file_url":"https://github.com/renyi-ai/moreau-yosida-f-divergences/blob/HEAD/gan_cifar10.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"c41924e881d94c2e"}},{"code_sha256_prefix":"55af3b8573d91d4d","entry":"conjugate_reverse_kl","repo":"renyi-ai/moreau-yosida-f-divergences","repo_kind":"official","path":"gan_cifar10.py","file_url":"https://github.com/renyi-ai/moreau-yosida-f-divergences/blob/HEAD/gan_cifar10.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"55af3b8573d91d4d"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}