SAP Warp is a Warp-based implementation of the SAP contact formulation from An Unconstrained Convex Formulation of Compliant Contact with additional improvements for robust, stable, and efficient simulation of frictional contact for robotics. The project follows Drake's implementation as a reference and exposes a compact Python/Warp runtime for scene loading, collision generation, solver benchmarking, and visualization.
This repository is initiated and maintained by the AIVC Lab and Toyota Research Institute (TRI).
SAP Warp is designed for CUDA-accelerated simulation and also supports CPU execution for lightweight runs.
We recommend using uv to set up the environment. To get started, run:
uv run python -m viewer.viser.sap_viewer \
--scene assets/yaml/unitree_g1_usd.yamlThe program will launch a Viser viewer which defaults to http://localhost:8080.
The repository includes several scene files under assets/yaml/.
![]() Basic cartpole |
![]() Basic ant |
![]() Franka Panda arm |
![]() AgileX Piper arm |
![]() Universal Robots UR10 |
![]() ANYmal C quadruped |
![]() ANYmal D quadruped |
![]() Unitree H1 humanoid |
![]() Unitree G1 humanoid |
For detailed SAP Warp documentation, see the documentation site.
SAP Warp is fully compatible with Newton. See this example and the documentation for more details.
uv run --frozen --with 'newton[examples]' python sap_with_newton.pyContributions are welcome. Please keep changes focused, include a small reproduction or benchmark command when possible, and update documentation for user-facing behavior.
Current core contributors: Yunuo Chen, Xiang Feng, Chang Yu, Yin Yang, Joseph Masterjohn, and Chenfanfu Jiang.
SAP Warp is released under the Apache 2.0 license. See LICENSE.
If you use SAP Warp in your research, please consider citing:
@misc{sapwarp,
author = {SAP Warp Developers},
title = {SAP Warp: GPU-accelerated Semi-Analytic Primal Solver for Compliant Frictional Contact},
month = {June},
year = {2026},
url = {https://github.com/sap-sim/sap_warp}
}








