{"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/flow-matching-for-generative-modeling","title":"Flow Matching for Generative Modeling","arxiv_id":"2210.02747","date":"2022-10-06","proceeding":null,"authors":["Yaron Lipman","Ricky T. Q. Chen","Heli Ben-Hamu","Maximilian Nickel","Matt Le"],"abstract":"We introduce a new paradigm for generative modeling built on Continuous Normalizing Flows (CNFs), allowing us to train CNFs at unprecedented scale. Specifically, we present the notion of Flow Matching (FM), a simulation-free approach for training CNFs based on regressing vector fields of fixed conditional probability paths. Flow Matching is compatible with a general family of Gaussian probability paths for transforming between noise and data samples -- which subsumes existing diffusion paths as specific instances. Interestingly, we find that employing FM with diffusion paths results in a more robust and stable alternative for training diffusion models. Furthermore, Flow Matching opens the door to training CNFs with other, non-diffusion probability paths. An instance of particular interest is using Optimal Transport (OT) displacement interpolation to define the conditional probability paths. These paths are more efficient than diffusion paths, provide faster training and sampling, and result in better generalization. Training CNFs using Flow Matching on ImageNet leads to consistently better performance than alternative diffusion-based methods in terms of both likelihood and sample quality, and allows fast and reliable sample generation using off-the-shelf numerical ODE solvers.","url_abs":"https://arxiv.org/abs/2210.02747v2","url_pdf":"https://arxiv.org/pdf/2210.02747v2.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":"flow-matching-for-generative-modeling","repo_url":"https://github.com/edapinenut/ppflow","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null},{"paper_slug":"flow-matching-for-generative-modeling","repo_url":"https://github.com/g4vrel/CFM","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null},{"paper_slug":"flow-matching-for-generative-modeling","repo_url":"https://github.com/jjunak-yun/FLowHigh_code","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}},{"paper_slug":"flow-matching-for-generative-modeling","repo_url":"https://github.com/shivammehta25/Matcha-TTS","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null},{"paper_slug":"flow-matching-for-generative-modeling","repo_url":"https://github.com/leffff/FlowModels","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":0,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"density-estimation","task_name":"Density Estimation"},{"task_slug":"image-generation","task_name":"Image Generation"}],"methods":[{"method_slug":"diffusion","method_name":"Diffusion"},{"method_slug":"normalizing-flows","method_name":"Normalizing Flows"}],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/density-estimation-on-cifar-10","task":"Density Estimation","dataset":"CIFAR-10","model":"Flow matching","rank_in_archive_order":9,"of":15,"metrics":{"NLL (bits/dim)":"2.99"},"uses_additional_data":false},{"leaderboard":"/sota/image-generation-on-cifar-10","task":"Image Generation","dataset":"CIFAR-10","model":"FM","rank_in_archive_order":37,"of":78,"metrics":{"FID":"6.35"},"uses_additional_data":false},{"leaderboard":"/sota/image-generation-on-imagenet-32x32","task":"Image Generation","dataset":"ImageNet 32x32","model":"FM","rank_in_archive_order":5,"of":35,"metrics":{"FID":"5.02","bpd":"3.53"},"uses_additional_data":false},{"leaderboard":"/sota/image-generation-on-imagenet-64x64","task":"Image Generation","dataset":"ImageNet 64x64","model":"FM","rank_in_archive_order":28,"of":65,"metrics":{"Bits per dim":"3.31","FID":"14.45"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2210.02747","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2210.02747"}},"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/edapinenut/ppflow","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/g4vrel/CFM","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/shivammehta25/Matcha-TTS","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/jjunak-yun/FLowHigh_code","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/leffff/FlowModels","reach":null}],"summary":{"ran":1,"unverified":3},"by_repo_kind":{"listed":{"samples":4,"ran":1,"repositories":3}},"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":3,"samples":[{"code_sha256_prefix":"a2ca2da84306fbf6","entry":"BASECFM","repo":"shivammehta25/Matcha-TTS","repo_kind":"listed","path":"matcha/models/components/flow_matching.py","file_url":"https://github.com/shivammehta25/Matcha-TTS/blob/HEAD/matcha/models/components/flow_matching.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"a2ca2da84306fbf6"}},{"code_sha256_prefix":"584c6ac502bd6d6d","entry":"OptimalTransportFlow","repo":"g4vrel/CFM","repo_kind":"listed","path":"flow.py","file_url":"https://github.com/g4vrel/CFM/blob/HEAD/flow.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":"584c6ac502bd6d6d"}},{"code_sha256_prefix":"06d76c9cd45a82cb","entry":"SO3ConditionalFlowMatcher","repo":"edapinenut/ppflow","repo_kind":"listed","path":"ppflow/modules/flows/flow_sampler.py","file_url":"https://github.com/edapinenut/ppflow/blob/HEAD/ppflow/modules/flows/flow_sampler.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":"06d76c9cd45a82cb"}},{"code_sha256_prefix":"5bc3d7ab75c8e2ac","entry":"riemannian_gradient","repo":"edapinenut/ppflow","repo_kind":"listed","path":"ppflow/modules/flows/flow_sampler.py","file_url":"https://github.com/edapinenut/ppflow/blob/HEAD/ppflow/modules/flows/flow_sampler.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":"5bc3d7ab75c8e2ac"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}