DiffPD: Differentiable Projective Dynamics

Abstract

We present a novel, fast differentiable simulator for soft-body learning and control applications. Existing differentiable soft-body simulators can be classified into two categories based on their time integration methods: Simulators using explicit timestepping schemes require tiny timesteps to avoid numerical instabilities in gradient computation, and simulators using implicit time integration typically compute gradients by employing the adjoint method and solving the expensive linearized dynamics. Inspired by Projective Dynamics (PD), we present Differentiable Projective Dynamics (DiffPD), an efficient differentiable soft-body simulator based on PD with implicit time integration. The key idea in DiffPD is to speed up backpropagation by exploiting the prefactorized Cholesky decomposition in forward PD simulation. In terms of contact handling, DiffPD supports two types of contacts: a penalty-based model describing contact and friction forces and a complementarity-based model enforcing non-penetration conditions and static friction. We evaluate the performance of DiffPD and observe it is 4–19 times faster compared with the standard Newton’s method in various applications including system identification, inverse design problems, trajectory optimization, and closed-loop control. We also apply DiffPD in a reality-to-simulation (real-to-sim) example with contact and collisions and show its capability of reconstructing a digital twin of real-world scenes.


Video


Acknowledgments

We thank Desai Chen, David I.W. Levin, Bo Zhu, and Eftychios Sifakis for their feedback and suggestions on this paper. The duck and cow mesh models in Figs. 5, 6, and 14 are obtained from Keenan Crane's 3D model repository under the CC0 1.0 Universal license. This work is sponsored by Defense Advanced Research Projects Agency (DARPA) under grant No. FA8750-20-C-0075, Intelligence Advanced Research Projects Activity (IARPA) under grant 2019- 19020100001, and National Science Foundation (NSF) Award 2106962: Computational Design of Complex Fluidic Systems.


Paper and Code

DiffPD: Differentiable Projective Dynamics
Tao Du, Kui Wu, Pingchuan Ma, Sebastien Wah, Andrew Spielberg, Daniela Rus, Wojciech Matusik
ACM Transactions on Graphics 2022 (SIGGRAPH 2022)
[Paper] [Code] [Slides]

Citation

@article{du2021_diffpd,
    author = {Du, Tao and Wu, Kui and Ma, Pingchuan and Wah, Sebastien and Spielberg, Andrew and Rus, Daniela and Matusik, Wojciech},
    title = {DiffPD: Differentiable Projective Dynamics},
    year = {2021},
    issue_date = {April 2022},
    publisher = {Association for Computing Machinery},
    address = {New York, NY, USA},
    volume = {41},
    number = {2},
    issn = {0730-0301},
    url = {https://doi.org/10.1145/3490168},
    doi = {10.1145/3490168},
    journal = {ACM Trans. Graph.},
    month = {nov},
    articleno = {13},
    numpages = {21},
    keywords = {differentiable simulation, Projective dynamics}
}