Abstract
Understanding the dynamics of human gait, including both motions and forces, is vital to promote human mobility. While deep learning models may have advantages over costly laboratory-based experiments and physics-based simulations, existing models have been trained on small datasets with homogeneous demographics and focus on predicting a single output. We developed GaitDynamics, a generative foundation model trained on a large dataset of diverse gait patterns, which allows for flexible inputs, outputs and clinical applications. We illustrate the use of GaitDynamics for: (1) estimating ground reaction forces from kinematics with high accuracy even with missing kinematic data, (2) predicting the effects of gait modifications on knee loading without resource-intensive experiments and (3) predicting kinematic and force changes that occur with increasing running speeds. Our results demonstrate the accuracy and efficiency of GaitDynamics, showing its potential to assess and optimize gait for injury prevention, disease treatment and performance coaching. All data, code and trained models are publicly shared.
This is a preview of subscription content, access via your institution
Access options
Access Nature and 54 other Nature Portfolio journals
Get Nature+, our best-value online-access subscription
$32.99 / 30 days
cancel any time
Subscribe to this journal
Receive 12 digital issues and online access to articles
$119.00 per year
only $9.92 per issue
Buy this article
- Purchase on SpringerLink
- Instant access to the full article PDF.
USD 39.95
Prices may be subject to local taxes which are calculated during checkout







Similar content being viewed by others
Data availability
This work utilized the AddBiomechanics dataset that consists of data from 15 previous studies (https://addbiomechanics.org/download_data.html). Source data are provided with this paper.
Code availability
The trained models and source codes are available on GitHub at https://github.com/stanfordnmbl/GaitDynamics (ref. 82). We also provide a Hugging Face demo for users to upload files with full- or partial-body kinematics, predict ground reaction forces and missing kinematics using GaitDynamics, and download the results (https://huggingface.co/spaces/alanttan/GaitDynamics). Note that we used the an OpenSim Rajagopal Model without Arms (https://simtk.org/projects/full_body)68, and a different skeletal model may lead to failure due to mismatching joint names.
References
Padua, D. A. & DiStefano, L. J. Sagittal plane knee biomechanics and vertical ground reaction forces are modified following ACL injury prevention programs: a systematic review. Sports Health 1, 165–173 (2009).
Lieberman, D. E. et al. Foot strike patterns and collision forces in habitually barefoot versus shod runners. Nature 463, 531–535 (2010).
Sharma, S., McMorland, A. J. C. & Stinear, J. W. Stance limb ground reaction forces in high functioning stroke and healthy subjects during gait initiation. Clin. Biomech. 30, 689–695 (2015).
Boehm, W. L. & Gruben, K. G. Post-stroke walking behaviors consistent with altered ground reaction force direction control advise new approaches to research and therapy. Transl. Stroke Res. 7, 3–11 (2016).
Esculier, J.-F., Bouyer, L. J. & Roy, J.-S. The effects of a multimodal rehabilitation program on symptoms and ground-reaction forces in runners with patellofemoral pain syndrome. J. Sport Rehabil. 25, 23–30 (2016).
Tan, T. et al. A scoping review of portable sensing for out-of-lab anterior cruciate ligament injury prevention and rehabilitation. npj Digit. Med. 6, 46 (2023).
Andriacchi, T. P. & Mündermann, A. The role of ambulatory mechanics in the initiation and progression of knee osteoarthritis. Curr. Opin. Rheumatol. 18, 514–518 (2006).
Shull, P. B. et al. Six-week gait retraining program reduces knee adduction moment, reduces pain, and improves function for individuals with medial compartment knee osteoarthritis. J. Orthop. Res. 31, 1020–1025 (2013).
Rynne, R., Le Tong, G., Cheung, R. T. H. & Constantinou, M. Effectiveness of gait retraining interventions in individuals with hip or knee osteoarthritis: a systematic review and meta-analysis. Gait Posture 95, 164–175 (2022).
Uhlrich, S. D. et al. Six weeks of personalized gait retraining to offload the medial compartment of the knee reduces pain more than sham gait retraining. Osteoarthr. Cartil. 27, S28 (2019).
Orendurff, M. S. et al. A little bit faster: lower extremity joint kinematics and kinetics as recreational runners achieve faster speeds. J. Biomech. 71, 167–175 (2018).
Haralabidis, N., Colyer, S. L., Serrancolí, G., Salo, A. I. T. & Cazzola, D. Modifications to the net knee moments lead to the greatest improvements in accelerative sprinting performance: a predictive simulation study. Sci. Rep. 12, 15908 (2022).
Piazza, S. J. Muscle-driven forward dynamic simulations for the study of normal and pathological gait. J. Neuroeng. Rehabil. 3, 5 (2006).
Uhlrich, S. D., Uchida, T. K., Lee, M. R. & Delp, S. L. Ten steps to becoming a musculoskeletal simulation expert: a half-century of progress and outlook for the future. J. Biomech. 154, 111623 (2023).
Dorschky, E., Nitschke, M., Seifer, A.-K., van den Bogert, A. J. & Eskofier, B. M. Estimation of gait kinematics and kinetics from inertial sensor data using optimal control of musculoskeletal models. J. Biomech. 95, 109278 (2019).
Falisse, A., Afschrift, M. & Groote, F. D. Modeling toes contributes to realistic stance knee mechanics in three-dimensional predictive simulations of walking. PLoS ONE 17, e0256311 (2022).
Ripic, Z. et al. Ground reaction force and joint moment estimation during gait using an Azure Kinect-driven musculoskeletal modeling approach. Gait Posture 95, 49–55 (2022).
Miller, R. H., Esterson, A. Y. & Shim, J. K. Joint contact forces when minimizing the external knee adduction moment by gait modification: a computer simulation study. Knee 22, 481–489 (2015).
Fregly, B. J., Reinbolt, J. A. & Chmielewski, T. L. Evaluation of a patient-specific cost function to predict the influence of foot path on the knee adduction torque during gait. Comput. Methods Biomech. Biomed. Eng. 11, 63–71 (2008).
Ong, C. F., Geijtenbeek, T., Hicks, J. L. & Delp, S. L. Predicting gait adaptations due to ankle plantarflexor muscle weakness and contracture using physics-based musculoskeletal simulations. PLoS Comput. Biol. 15, e1006993 (2019).
Han, X. et al. GroundLink: a dataset unifying human body movement and ground reaction dynamics. In SIGGRAPH Asia 2023 Conference Papers 1–10 (Association for Computing Machinery, 2023).
Sugai, R. et al. LSTM network-based estimation of ground reaction forces during walking in stroke patients using markerless motion capture system. IEEE Trans. Med. Robot. Bionics 5, 1016–1024 (2023).
Johnson, W. R., Alderson, J., Lloyd, D. & Mian, A. Predicting athlete ground reaction forces and moments from spatio-temporal driven CNN models. IEEE Trans. Biomed. Eng. 66, 689–694 (2019).
Bergamo, G. et al. Individualized learning-based ground reaction force estimation in people post-stroke using pressure insoles. In 2023 International Conference on Rehabilitation Robotics (ICORR) 1–6 (IEEE, 2023).
Donahue, S. R. & Hahn, M. E. Estimation of gait events and kinetic waveforms with wearable sensors and machine learning when running in an unconstrained environment. Sci. Rep. 13, 2339 (2023).
Bommasani, R. et al. On the opportunities and risks of foundation models. Preprint at https://doi.org/10.48550/arXiv.2108.07258 (2022).
Werling, K. et al. AddBiomechanics Dataset: capturing the physics of human motion at scale. In Proc. Computer Vision – ECCV 2024 (eds Leonardis, A. et al.) 490–508 (Springer Nature, 2025).
Falisse, A. et al. Rapid predictive simulations with complex musculoskeletal models suggest that diverse healthy and pathological human gaits can emerge from similar control strategies. J. R. Soc. Interface 16, 20190402 (2019).
D’Hondt, L., Groote, F. D. & Afschrift, M. A dynamic foot model for predictive simulations of human gait reveals causal relations between foot structure and whole-body mechanics. PLoS Comput. Biol. 20, e1012219 (2024).
Hammond, C. V. et al. The neuromusculoskeletal modeling pipeline: MATLAB-based model personalization and treatment optimization functionality for OpenSim. J. NeuroEng. Rehabil. 22, 112 (2025).
Patoz, A., Lussiana, T., Breine, B., Gindre, C. & Malatesta, D. Comparison of different machine learning models to enhance sacral acceleration-based estimations of running stride temporal variables and peak vertical ground reaction force. Sports Biomech. 24, 825–841 (2025).
Al-Amri, M., Al Balushi, H. & Mashabi, A. Intra-rater repeatability of gait parameters in healthy adults during self-paced treadmill-based virtual reality walking. Comput. Methods Biomech. Biomed. Eng. 20, 1669–1677 (2017).
Kesar, T. M., Binder-Macleod, S. A., Hicks, G. E. & Reisman, D. S. Minimal detectable change for gait variables collected during treadmill walking in individuals post-stroke. Gait Posture 33, 314–317 (2011).
Beckerman, H. et al. Smallest real difference, a link between reproducibility and responsiveness. Qual. Life Res. 10, 571–578 (2001).
Mündermann, A., Asay, J. L., Mündermann, L. & Andriacchi, T. P. Implications of increased medio-lateral trunk sway for ambulatory mechanics. J. Biomech. 41, 165–170 (2008).
Hunt, M. A. et al. Lateral trunk lean explains variation in dynamic knee joint load in patients with medial compartment knee osteoarthritis. Osteoarthr. Cartil. 16, 591–599 (2008).
Hurwitz, D. E., Ryals, A. B., Case, J. P., Block, J. A. & Andriacchi, T. P. The knee adduction moment during gait in subjects with knee osteoarthritis is more closely correlated with static alignment than radiographic disease severity, toe out angle and pain. J. Orthop. Res. 20, 101–107 (2002).
Miyazaki, T. et al. Dynamic load at baseline can predict radiographic disease progression in medial compartment knee osteoarthritis. Ann. Rheum. Dis. 61, 617–622 (2002).
Chehab, E. F., Favre, J., Erhart-Hledik, J. C. & Andriacchi, T. P. Baseline knee adduction and flexion moments during walking are both associated with 5 year cartilage changes in patients with medial knee osteoarthritis. Osteoarthr. Cartil. 22, 1833–1839 (2014).
Uhlrich, S. D. et al. OpenCap: Human movement dynamics from smartphone videos. PLoS Comput. Biol. 19, e1011462 (2023).
Chung, H., Kim, J., Mccann, M. T., Klasky, M. L. & Ye, J. C. Diffusion posterior sampling for general noisy inverse problems. In The Eleventh International Conference on Learning Representations 1–30 (ICLR, 2023).
Yang, L. et al. Guidance with spherical Gaussian constraint for conditional diffusion. In Proc. 41st International Conference on Machine Learning 235 56071–56095 (JMLR, 2024).
Huang, W., Jiang, Y., Van Wouwe, T. & Liu, C. K. Constrained diffusion with trust sampling. Adv. Neural Inf. Process. Syst. 37, 93849–93873 (2024).
Hamner, S. R. & Delp, S. L. Muscle contributions to fore-aft and vertical body mass center accelerations over a range of running speeds. J. Biomech. 46, 780–787 (2013).
Xie, Y., Jampani, V., Zhong, L., Sun, D. & Jiang, H. OmniControl: control any joint at any time for human motion generation. In The Twelfth International Conference on Learning Representations 1–19 (ICLR, 2024).
Li, J. et al. DataComp-LM: in search of the next generation of training sets for language models. Adv. Neural Inf. Process. Syst. 37, 14200–14282 (2024).
Weber, M. et al. RedPajama: an open dataset for training large language models. Adv. Neural Inf. Process. Syst. 37, 116462–116492 (2024).
Tan, T., Wang, D., Shull, P. B. & Halilaj, E. IMU and smartphone camera fusion for knee adduction and knee flexion moment estimation during walking. IEEE Trans. Industr. Inform. 19, 1445–1455 (2023).
Carter, J., Chen, X., Cazzola, D., Trewartha, G. & Preatoni, E. Consumer-priced wearable sensors combined with deep learning can be used to accurately predict ground reaction forces during various treadmill running conditions. PeerJ 12, e17896 (2024).
Dembia, C. L., Bianco, N. A., Falisse, A., Hicks, J. L. & Delp, S. L. OpenSim Moco: musculoskeletal optimal control. PLoS Comput. Biol. 16, e1008493 (2020).
Bicer, M., Phillips, A. T. M., Melis, A., McGregor, A. H. & Modenese, L. Generative deep learning applied to biomechanics: a new augmentation technique for motion capture datasets. J. Biomech. 144, 111301 (2022).
Cotton, R. J. et al. in Predictive Intelligence in Medicine (eds Rekik, I. et al.) 277–291 (Springer Nature, 2023).
Tan, T., Shull, P. B., Hicks, J. L., Uhlrich, S. D. & Chaudhari, A. S. Self-supervised learning improves accuracy and data efficiency for IMU-based ground reaction force estimation. IEEE Trans. Biomed. Eng. 71, 2095–2104 (2024).
Park, J., Park, M. S., Lee, J. & Won, J. Bidirectional GaitNet: a bidirectional prediction model of human gait and anatomical conditions. In Proc. ACM SIGGRAPH 2023 Conference 1–9 (Association for Computing Machinery, 2023).
Luo, S. et al. Experiment-free exoskeleton assistance via learning in simulation. Nature 630, 353–359 (2024).
Camargo, J., Ramanathan, A., Flanagan, W. & Young, A. A comprehensive, open-source dataset of lower limb biomechanics in multiple conditions of stairs, ramps, and level-ground ambulation and transitions. J. Biomech. 119, 110320 (2021).
Moore, J. K., Hnat, S. K. & van den Bogert, A. J. An elaborate data set on human gait and the effect of mechanical perturbations. PeerJ 3, e918 (2015).
van der Zee, T. J., Mundinger, E. M. & Kuo, A. D. A biomechanics dataset of healthy human walking at various speeds, step lengths and step widths. Sci. Data 9, 704 (2022).
Wang, H., Basu, A., Durandau, G. & Sartori, M. A wearable real-time kinetic measurement sensor setup for human locomotion. Wearable Technol. 4, e11 (2023).
Carter, J., Chen, X., Cazzola, D., Trewartha, G. & Preatoni, E. Full Body Kinematics and Ground Reaction Forces of Fifty Heterogeneous Runners Completing Treadmill Running at Various Speeds and Gradients (Univ. Bath, 2024).
Tan, T., Strout, Z. A., Cheung, R. T. H. & Shull, P. B. Strike index estimation using a convolutional neural network with a single, shoe-mounted inertial sensor. J. Biomech. 139, 111145 (2022).
Falisse, A., Van Rossom, S., Jonkers, I. & De Groote, F. EMG-driven optimal estimation of subject-specific Hill Model muscle–tendon parameters of the knee joint actuators. IEEE Trans. Biomed. Eng. 64, 2253–2262 (2017).
Lencioni, T., Carpinella, I., Rabuffetti, M., Marzegan, A. & Ferrarin, M. Human kinematic, kinetic and EMG data during different walking and stair ascending and descending tasks. Sci. Data 6, 309 (2019).
Fregly, B. J. et al. Grand challenge competition to predict in vivo knee loads. J. Orthop. Res. 30, 503–513 (2012).
Li, G., Shourijeh, M. S., Ao, D., Patten, C. & Fregly, B. J. How well do commonly used co-contraction indices approximate lower limb joint stiffness trends during gait for individuals post-stroke? Front. Bioeng. Biotechnol. 8, 588908 (2021).
dos Santos, D. A., Fukuchi, C. A., Fukuchi, R. K. & Duarte, M. A data set with kinematic and ground reaction forces of human balance. PeerJ 5, e3626 (2017).
Werling, K. et al. AddBiomechanics: automating model scaling, inverse kinematics, and inverse dynamics from human motion data through sequential optimization. PLoS ONE 18, e0295152 (2023).
Rajagopal, A. et al. Full-body musculoskeletal model for muscle-driven simulation of human gait. IEEE Trans. Biomed. Eng. 63, 2068–2079 (2016).
Seth, A. et al. OpenSim: simulating musculoskeletal dynamics and neuromuscular control to study human and animal movement. PLoS Comput. Biol. 14, e1006223 (2018).
de Boor, C. On calculating with B-splines. J. Approx. Theory 6, 50–62 (1972).
Jazar, R. N. in Theory of Applied Robotics: Kinematics, Dynamics, and Control (ed. Jazar, R. N.) 361–413 (Springer, 2022).
Zhou, Y., Barnes, C., Lu, J., Yang, J. & Li, H. On the continuity of rotation representations in neural networks. In 2019 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR) 5738–5746 (IEEE, 2019).
Leskinen, A., Häkkinen, K., Virmavirta, M., Isolehto, J. & Kyröläinen, H. Comparison of running kinematics between elite and national-standard 1500-m runners. Sports Biomech. 8, 1–9 (2009).
Van Wouwe, T., Lee, S., Falisse, A., Delp, S. & Liu, C. K. DiffusionPoser: real-time human motion reconstruction from arbitrary sparse sensors using autoregressive diffusion. In 2024 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR) 2513–2523 (IEEE, 2024).
Tseng, J., Castellon, R. & Liu, C. K. EDGE: editable dance generation from music. In 2023 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR) 448–458 (IEEE, 2023).
Ho, J., Jain, A. & Abbeel, P. Denoising diffusion probabilistic models. In Proc. 34th International Conference on Neural Information Processing Systems 6840–6851 (Curran Associates, 2020).
Su, J. et al. RoFormer: enhanced transformer with rotary position embedding. Neurocomputing 568, 127063 (2024).
Xie, X., Zhou, P., Li, H., Lin, Z. & Yan, S. Adan: adaptive Nesterov momentum algorithm for faster optimizing deep models. IEEE Trans. Pattern Anal. Mach. Intell. 46, 9508–9520 (2024).
Song, J., Meng, C. & Ermon, S. Denoising diffusion implicit models. In International Conference on Learning Representations Poster (ICLR, 2021).
Lugmayr, A. et al. RePaint: inpainting using denoising diffusion probabilistic models. In 2022 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR) 11461–11471 (IEEE, 2022).
Rutherford, D. J. & Baker, M. Knee moment outcomes using inverse dynamics and the cross product function in moderate knee osteoarthritis gait: a comparison study. J. Biomech. 78, 150–154 (2018).
Tan, T. GaitDynamics. GitHub https://github.com/stanfordnmbl/GaitDynamics (2025).
Acknowledgements
This work was supported by the Joe and Clara Tsai Foundation through the Wu Tsai Human Performance Alliance, and by the US National Institutes of Health (NIH) under Grants P50 HD118632, P41 EB027060, P2C HD101913, R01 AR077604, R01 EB002524 and R01 AR079431.
Author information
Authors and Affiliations
Contributions
All authors contributed to the conception of the work. T.T., T.V.W. and K.F.W. worked on data analysis. T.T. drafted the manuscript. All authors critically revised the manuscript and approved the final version.
Corresponding author
Ethics declarations
Competing interests
The authors declare no competing interests.
Peer review
Peer review information
Nature Biomedical Engineering thanks Markus Wimmer and the other, anonymous, reviewer(s) for their contribution to the peer review of this work. Peer reviewer reports are available.
Additional information
Publisher’s note Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Supplementary information
Supplementary Information (download PDF )
Supplementary Tables 1–3 and Figs. 1–5.
Source data
Source Data Fig. 3 (download XLSX )
Statistical source data.
Source Data Fig. 4 (download XLSX )
Statistical source data.
Source Data Fig. 6 (download XLSX )
Statistical source data.
Source Data Fig. 7 (download XLSX )
Statistical source data.
Rights and permissions
Springer Nature or its licensor (e.g. a society or other partner) holds exclusive rights to this article under a publishing agreement with the author(s) or other rightsholder(s); author self-archiving of the accepted manuscript version of this article is solely governed by the terms of such publishing agreement and applicable law.
About this article
Cite this article
Tan, T., Van Wouwe, T., Werling, K.F. et al. GaitDynamics: a generative foundation model for analyzing human walking and running. Nat. Biomed. Eng (2026). https://doi.org/10.1038/s41551-025-01565-8
Received:
Accepted:
Published:
Version of record:
DOI: https://doi.org/10.1038/s41551-025-01565-8


