{"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/mixed-gaussian-flow-for-diverse-trajectory","title":"MGF: Mixed Gaussian Flow for Diverse Trajectory Prediction","arxiv_id":"2402.12238","date":"2024-02-19","proceeding":null,"authors":["Jiahe Chen","Jinkun Cao","Dahua Lin","Kris Kitani","Jiangmiao Pang"],"abstract":"To predict future trajectories, the normalizing flow with a standard Gaussian prior suffers from weak diversity. The ineffectiveness comes from the conflict between the fact of asymmetric and multi-modal distribution of likely outcomes and symmetric and single-modal original distribution and supervision losses. Instead, we propose constructing a mixed Gaussian prior for a normalizing flow model for trajectory prediction. The prior is constructed by analyzing the trajectory patterns in the training samples without requiring extra annotations while showing better expressiveness and being multi-modal and asymmetric. Besides diversity, it also provides better controllability for probabilistic trajectory generation. We name our method Mixed Gaussian Flow (MGF). It achieves state-of-the-art performance in the evaluation of both trajectory alignment and diversity on the popular UCY/ETH and SDD datasets. Code is available at https://github.com/mulplue/MGF.","url_abs":"https://arxiv.org/abs/2402.12238v2","url_pdf":"https://arxiv.org/pdf/2402.12238v2.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":"mixed-gaussian-flow-for-diverse-trajectory","repo_url":"https://github.com/mulplue/mgf","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"diversity","task_name":"Diversity"},{"task_slug":"prediction","task_name":"Prediction"},{"task_slug":"trajectory-prediction","task_name":"Trajectory Prediction"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":"https://syntology.ai/paper/2402.12238","atlas_url":"https://app.syntology.ai/?focus=2402.12238","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2402.12238"}},"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/mulplue/MGF","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/mulplue/mgf","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"ran":16,"ran_draft_wrong":5,"unverified":9},"by_repo_kind":{"official":{"samples":30,"ran":21,"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":"5b716a5982a339d2","entry":"BatchNorm","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"5b716a5982a339d2"}},{"code_sha256_prefix":"2826248c43f41a45","entry":"Build_TP_model","repo":"mulplue/MGF","repo_kind":"official","path":"src/models/TP/TP_models.py","file_url":"https://github.com/mulplue/MGF/blob/HEAD/src/models/TP/TP_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":"2826248c43f41a45"}},{"code_sha256_prefix":"a0ca33c8b6e66193","entry":"CIF_step","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"a0ca33c8b6e66193"}},{"code_sha256_prefix":"b9e0ff9a558438e1","entry":"DiagonalGaussianConditionalDensity","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"b9e0ff9a558438e1"}},{"code_sha256_prefix":"4d0d2d2745b54b63","entry":"LinearMaskedCoupling","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"4d0d2d2745b54b63"}},{"code_sha256_prefix":"26209689fe626f49","entry":"MADE","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"26209689fe626f49"}},{"code_sha256_prefix":"ca93d4c44305509b","entry":"MaskedLinear","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"ca93d4c44305509b"}},{"code_sha256_prefix":"90c765ce469cc84d","entry":"cluster_GMM_Dist","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"90c765ce469cc84d"}},{"code_sha256_prefix":"920ca1a223d05c89","entry":"create_RealNVP_step","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"920ca1a223d05c89"}},{"code_sha256_prefix":"5a2e1cee97642f25","entry":"create_masks","repo":"mulplue/MGF","repo_kind":"official","path":"src/models/TP/TFCondARFlow.py","file_url":"https://github.com/mulplue/MGF/blob/HEAD/src/models/TP/TFCondARFlow.py","link_basis":"plan_row","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":"5a2e1cee97642f25"}},{"code_sha256_prefix":"ff1848a826b358a0","entry":"cyclical_lr","repo":"mulplue/MGF","repo_kind":"official","path":"src/models/TP/model_utils.py","file_url":"https://github.com/mulplue/MGF/blob/HEAD/src/models/TP/model_utils.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":"ff1848a826b358a0"}},{"code_sha256_prefix":"507ad74b8141f11f","entry":"diagonal_gaussian_log_prob","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"507ad74b8141f11f"}},{"code_sha256_prefix":"9b77c0354d2d0aaa","entry":"diagonal_gaussian_sample","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"9b77c0354d2d0aaa"}},{"code_sha256_prefix":"283aa4275dc465c0","entry":"displacement_error","repo":"mulplue/MGF","repo_kind":"official","path":"src/metrics/TP_metrics.py","file_url":"https://github.com/mulplue/MGF/blob/HEAD/src/metrics/TP_metrics.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"283aa4275dc465c0"}},{"code_sha256_prefix":"9bb40f2536a46a93","entry":"evaluate_helper","repo":"mulplue/MGF","repo_kind":"official","path":"src/metrics/TP_metrics.py","file_url":"https://github.com/mulplue/MGF/blob/HEAD/src/metrics/TP_metrics.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":"9bb40f2536a46a93"}},{"code_sha256_prefix":"ddbf6d5de516a0dc","entry":"evaluate_helper_mean","repo":"mulplue/MGF","repo_kind":"official","path":"src/metrics/TP_metrics.py","file_url":"https://github.com/mulplue/MGF/blob/HEAD/src/metrics/TP_metrics.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":"ddbf6d5de516a0dc"}},{"code_sha256_prefix":"6b2d284bebc1dc60","entry":"exp_anneal","repo":"mulplue/MGF","repo_kind":"official","path":"src/models/TP/model_utils.py","file_url":"https://github.com/mulplue/MGF/blob/HEAD/src/models/TP/model_utils.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":"6b2d284bebc1dc60"}},{"code_sha256_prefix":"3508c00acbc73d66","entry":"get_mlp","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"3508c00acbc73d66"}},{"code_sha256_prefix":"5a0beb315ee2d6b3","entry":"get_model_device","repo":"mulplue/MGF","repo_kind":"official","path":"src/models/TP/Trajectron.py","file_url":"https://github.com/mulplue/MGF/blob/HEAD/src/models/TP/Trajectron.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":"5a0beb315ee2d6b3"}},{"code_sha256_prefix":"92dfbf360b9c387e","entry":"load_tuned","repo":"mulplue/MGF","repo_kind":"official","path":"src/utils/common.py","file_url":"https://github.com/mulplue/MGF/blob/HEAD/src/utils/common.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":"92dfbf360b9c387e"}},{"code_sha256_prefix":"8f0b65c232680906","entry":"to_one_hot","repo":"mulplue/MGF","repo_kind":"official","path":"src/models/TP/model_utils.py","file_url":"https://github.com/mulplue/MGF/blob/HEAD/src/models/TP/model_utils.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":"8f0b65c232680906"}},{"code_sha256_prefix":"6ebdf632e0a6ad62","entry":"Build_Metrics","repo":"mulplue/MGF","repo_kind":"official","path":"src/metrics/build_metrics.py","file_url":"https://github.com/mulplue/MGF/blob/HEAD/src/metrics/build_metrics.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":"6ebdf632e0a6ad62"}},{"code_sha256_prefix":"f8f3b999a11d5d3e","entry":"FlowSequential","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"f8f3b999a11d5d3e"}},{"code_sha256_prefix":"70f0ce27583cb926","entry":"create_MAF_step","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"70f0ce27583cb926"}},{"code_sha256_prefix":"53b654d10ae7d946","entry":"fastpredNF","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"53b654d10ae7d946"}},{"code_sha256_prefix":"e762f39de147d718","entry":"fastpredNF_CIF_separate_cond","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"e762f39de147d718"}},{"code_sha256_prefix":"4effd10a00bbdc37","entry":"fastpredNF_CIF_separate_cond_clusterGMM","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"4effd10a00bbdc37"}},{"code_sha256_prefix":"ef3d886fa6434784","entry":"fastpredNF_separate","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"ef3d886fa6434784"}},{"code_sha256_prefix":"8f74fa4acbfdec65","entry":"fastpredNF_separate_cond","repo":"mulplue/mgf","repo_kind":"official","path":"src/models/TP/fastpredNF.py","file_url":"https://github.com/mulplue/mgf/blob/HEAD/src/models/TP/fastpredNF.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":"8f74fa4acbfdec65"}},{"code_sha256_prefix":"e158e0cb62772b3d","entry":"load_config","repo":"mulplue/MGF","repo_kind":"official","path":"src/utils/common.py","file_url":"https://github.com/mulplue/MGF/blob/HEAD/src/utils/common.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":"e158e0cb62772b3d"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}