{"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/learning-to-simulate-complex-physics-with","title":"Learning to Simulate Complex Physics with Graph Networks","arxiv_id":"2002.09405","date":"2020-02-21","proceeding":"ICML 2020 1","authors":["Alvaro Sanchez-Gonzalez","Jonathan Godwin","Tobias Pfaff","Rex Ying","Jure Leskovec","Peter W. Battaglia"],"abstract":"Here we present a machine learning framework and model implementation that can learn to simulate a wide variety of challenging physical domains, involving fluids, rigid solids, and deformable materials interacting with one another. Our framework---which we term \"Graph Network-based Simulators\" (GNS)---represents the state of a physical system with particles, expressed as nodes in a graph, and computes dynamics via learned message-passing. Our results show that our model can generalize from single-timestep predictions with thousands of particles during training, to different initial conditions, thousands of timesteps, and at least an order of magnitude more particles at test time. Our model was robust to hyperparameter choices across various evaluation metrics: the main determinants of long-term performance were the number of message-passing steps, and mitigating the accumulation of error by corrupting the training data with noise. Our GNS framework advances the state-of-the-art in learned physical simulation, and holds promise for solving a wide range of complex forward and inverse problems.","url_abs":"https://arxiv.org/abs/2002.09405v2","url_pdf":"https://arxiv.org/pdf/2002.09405v2.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":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/deepmind/deepmind-research","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"tf","reach":null},{"paper_slug":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/Darkneew/deeplearning-fluid","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"tf","reach":{"status":"ok"}},{"paper_slug":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/Lancial/GNN-Particle-Physics-Simulator","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"tf","reach":{"status":"ok"}},{"paper_slug":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/cogtoolslab/physics-benchmarking-neurips2021","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"none","reach":null},{"paper_slug":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/diogodcarvalho/gns-sheet-model","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"jax","reach":{"status":"ok","spdx":"MIT"}},{"paper_slug":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/geoelements/gns","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null},{"paper_slug":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/htung0101/Physion-particles","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null},{"paper_slug":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/jlinki/ggns","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok"}},{"paper_slug":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/kks32/learning_to_simulate","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"tf","reach":{"status":"ok"}},{"paper_slug":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/m-ulmestrand/gcn-collisions","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null},{"paper_slug":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/tumaer/lagrangebench","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"jax","reach":{"status":"ok","spdx":"MIT"}},{"paper_slug":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/wu375/gnn-sim-torch","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok"}},{"paper_slug":"learning-to-simulate-complex-physics-with","repo_url":"https://github.com/wu375/simple-physics-simulator-pytorch-geometry","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok"}}],"tasks":[],"methods":[{"method_slug":"gns","method_name":"GNS"},{"method_slug":"test","method_name":"Test"}],"datasets_introduced":[],"methods_introduced":[{"slug":"gns","name":"GNS","full_name":"Graph Network-based Simulators"}],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2002.09405","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2002.09405"}},"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/deepmind/deepmindresearch","reach":{"status":"unanswered"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/deepmind/deepmind-research","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/tumaer/lagrangebench","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/wu375/simple-physics-simulator-pytorch-geometry","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/htung0101/Physion-particles","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/Darkneew/deeplearning-fluid","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/diogodcarvalho/gns-sheet-model","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/geoelements/gns","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/jlinki/ggns","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/m-ulmestrand/gcn-collisions","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/Lancial/GNN-Particle-Physics-Simulator","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/kks32/learning_to_simulate","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/wu375/gnn-sim-torch","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/cogtoolslab/physics-benchmarking-neurips2021","reach":null}],"summary":{"ran":7,"ran_fixture":1,"ran_violates":1,"unverified":15},"by_repo_kind":{"listed":{"samples":24,"ran":9,"repositories":4}},"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":13,"samples":[{"code_sha256_prefix":"cf515f1865cc938d","entry":"Decoder","repo":"geoelements/gns","repo_kind":"listed","path":"gns/learned_simulator.py","file_url":"https://github.com/geoelements/gns/blob/HEAD/gns/learned_simulator.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"invariant","behaviour_fingerprint":true,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"cf515f1865cc938d"}},{"code_sha256_prefix":"31391488600b96f6","entry":"Encoder","repo":"geoelements/gns","repo_kind":"listed","path":"gns/learned_simulator.py","file_url":"https://github.com/geoelements/gns/blob/HEAD/gns/learned_simulator.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"31391488600b96f6"}},{"code_sha256_prefix":"6ddd7d872c5465bd","entry":"GCN","repo":"m-ulmestrand/gcn-collisions","repo_kind":"listed","path":"physics_gnn.py","file_url":"https://github.com/m-ulmestrand/gcn-collisions/blob/HEAD/physics_gnn.py","link_basis":"first_harvest_node","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":"6ddd7d872c5465bd"}},{"code_sha256_prefix":"455f17e20452375a","entry":"ParticleEncoder","repo":"htung0101/Physion-particles","repo_kind":"listed","path":"models/GNS.py","file_url":"https://github.com/htung0101/Physion-particles/blob/HEAD/models/GNS.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"455f17e20452375a"}},{"code_sha256_prefix":"52aa4c6dfc0568cf","entry":"ParticlePredictor","repo":"htung0101/Physion-particles","repo_kind":"listed","path":"models/GNS.py","file_url":"https://github.com/htung0101/Physion-particles/blob/HEAD/models/GNS.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"52aa4c6dfc0568cf"}},{"code_sha256_prefix":"2ec08f9afc4481a9","entry":"Propagator","repo":"htung0101/Physion-particles","repo_kind":"listed","path":"models/GNS.py","file_url":"https://github.com/htung0101/Physion-particles/blob/HEAD/models/GNS.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"2ec08f9afc4481a9"}},{"code_sha256_prefix":"0b5db1c272bb2421","entry":"RelationEncoder","repo":"htung0101/Physion-particles","repo_kind":"listed","path":"models/GNS.py","file_url":"https://github.com/htung0101/Physion-particles/blob/HEAD/models/GNS.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"0b5db1c272bb2421"}},{"code_sha256_prefix":"b7cb81770ba30c93","entry":"build_mlp","repo":"geoelements/gns","repo_kind":"listed","path":"gns/learned_simulator.py","file_url":"https://github.com/geoelements/gns/blob/HEAD/gns/learned_simulator.py","link_basis":"first_harvest_node","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"b7cb81770ba30c93"}},{"code_sha256_prefix":"b6a7b4c1838c5223","entry":"time_diff","repo":"geoelements/gns","repo_kind":"listed","path":"gns/learned_simulator.py","file_url":"https://github.com/geoelements/gns/blob/HEAD/gns/learned_simulator.py","link_basis":"first_harvest_node","language":"python","status":"ran_violates","verification_level":1,"contract_check":"VIOLATES","metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"b6a7b4c1838c5223"}},{"code_sha256_prefix":"70132227e453c957","entry":"EncodeProcessDecode","repo":"geoelements/gns","repo_kind":"listed","path":"gns/learned_simulator.py","file_url":"https://github.com/geoelements/gns/blob/HEAD/gns/learned_simulator.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"70132227e453c957"}},{"code_sha256_prefix":"7404c27d0f9f05b1","entry":"GNS","repo":"htung0101/Physion-particles","repo_kind":"listed","path":"models/GNS.py","file_url":"https://github.com/htung0101/Physion-particles/blob/HEAD/models/GNS.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":"7404c27d0f9f05b1"}},{"code_sha256_prefix":"eb8cb787e8ea787c","entry":"InteractionNetwork","repo":"geoelements/gns","repo_kind":"listed","path":"gns/learned_simulator.py","file_url":"https://github.com/geoelements/gns/blob/HEAD/gns/learned_simulator.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"eb8cb787e8ea787c"}},{"code_sha256_prefix":"ceb019d0bc5e6951","entry":"LearnedSimulator","repo":"geoelements/gns","repo_kind":"listed","path":"gns/learned_simulator.py","file_url":"https://github.com/geoelements/gns/blob/HEAD/gns/learned_simulator.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"ceb019d0bc5e6951"}},{"code_sha256_prefix":"4e185c59b88aa7c1","entry":"Processor","repo":"geoelements/gns","repo_kind":"listed","path":"gns/learned_simulator.py","file_url":"https://github.com/geoelements/gns/blob/HEAD/gns/learned_simulator.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"4e185c59b88aa7c1"}},{"code_sha256_prefix":"1c5a15d5ff809dc8","entry":"add_guards","repo":"diogodcarvalho/gns-sheet-model","repo_kind":"listed","path":"gns/graph.py","file_url":"https://github.com/diogodcarvalho/gns-sheet-model/blob/HEAD/gns/graph.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":"1c5a15d5ff809dc8"}},{"code_sha256_prefix":"7bf66991b886466a","entry":"get_E","repo":"diogodcarvalho/gns-sheet-model","repo_kind":"listed","path":"sheet_model/utils.py","file_url":"https://github.com/diogodcarvalho/gns-sheet-model/blob/HEAD/sheet_model/utils.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":"7bf66991b886466a"}},{"code_sha256_prefix":"462dc344aeb7e330","entry":"get_E","repo":"diogodcarvalho/gns-sheet-model","repo_kind":"listed","path":"gns/utils.py","file_url":"https://github.com/diogodcarvalho/gns-sheet-model/blob/HEAD/gns/utils.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":"462dc344aeb7e330"}},{"code_sha256_prefix":"4eb7506dd92f169f","entry":"get_dx_eq","repo":"diogodcarvalho/gns-sheet-model","repo_kind":"listed","path":"sheet_model/utils.py","file_url":"https://github.com/diogodcarvalho/gns-sheet-model/blob/HEAD/sheet_model/utils.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":"4eb7506dd92f169f"}},{"code_sha256_prefix":"074d15f05b987c6d","entry":"get_dx_eq","repo":"diogodcarvalho/gns-sheet-model","repo_kind":"listed","path":"gns/utils.py","file_url":"https://github.com/diogodcarvalho/gns-sheet-model/blob/HEAD/gns/utils.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":"074d15f05b987c6d"}},{"code_sha256_prefix":"ddb2cf246db8631b","entry":"get_guards","repo":"diogodcarvalho/gns-sheet-model","repo_kind":"listed","path":"gns/graph.py","file_url":"https://github.com/diogodcarvalho/gns-sheet-model/blob/HEAD/gns/graph.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":"ddb2cf246db8631b"}},{"code_sha256_prefix":"d1ea23cc7d33967b","entry":"get_nodes","repo":"diogodcarvalho/gns-sheet-model","repo_kind":"listed","path":"gns/graph.py","file_url":"https://github.com/diogodcarvalho/gns-sheet-model/blob/HEAD/gns/graph.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":"d1ea23cc7d33967b"}},{"code_sha256_prefix":"72df1c0ddb18d5ee","entry":"get_x_eq","repo":"diogodcarvalho/gns-sheet-model","repo_kind":"listed","path":"sheet_model/utils.py","file_url":"https://github.com/diogodcarvalho/gns-sheet-model/blob/HEAD/sheet_model/utils.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":"72df1c0ddb18d5ee"}},{"code_sha256_prefix":"95d152d025eca082","entry":"get_x_eq","repo":"diogodcarvalho/gns-sheet-model","repo_kind":"listed","path":"gns/utils.py","file_url":"https://github.com/diogodcarvalho/gns-sheet-model/blob/HEAD/gns/utils.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":"95d152d025eca082"}},{"code_sha256_prefix":"04256ab5e36f1f1b","entry":"sliding_windows","repo":"diogodcarvalho/gns-sheet-model","repo_kind":"listed","path":"gns/preprocess.py","file_url":"https://github.com/diogodcarvalho/gns-sheet-model/blob/HEAD/gns/preprocess.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":"04256ab5e36f1f1b"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}