This package implements mesh-to-mesh and mesh-to-robot-sphere-swept-volume collision detection algorithms using NVIDIA OptiX.
![]() |
![]() |
![]() |
![]() |
(a) | (b) | (c) | (d) |
Ray tracing collision detection methods: discrete-pose collision detection by ray-tracing (a) along obstacle meshes and (b) along robot meshes, and continuous collision detection by ray-tracing against swept sphere-approximated robot volumes (c) piecewise-linear paths or (d) quadratic B-spline paths.
- Upload the source code.
- URDF parser. (How to setup a new robot)
- Merge RobotToObs and ObsToRobot (Two-way method)
- Upload modified GVDB.
- Enable self-collision
- Adapt curve representation for Blackwell Architecture
![]() |
![]() |
ObsToRobot | RobotToObs |
![]() |
![]() |
![]() |
Dense Scene | Medium Scene | Simple Scene |
Despite performing a much more complex collision check than cuRobo (mesh-to-mesh vs. mesh-to-sphere), our methods outpaced cuRobo by up to 2.8x on medium to dense scenes, scaling past CPU performance at smaller batch sizes.
![]() |
![]() |
![]() |
Dense Scene | Medium Scene | Simple Scene |
Our piecewise-linear and discretized methods outpaced cuRobo on all except large batch sizes on simple scenes, with discretization being the fastest on dense scenes at the cost of recall rate. Quadratic B-splines had the best accuracy at slower speeds, but were still faster than cuRobo at most batch sizes for medium/dense scenes.
A RTX GPU is required to run this program.
I used vcpkg to manage most of the dependencies. You can install it from here. After installing vcpkg, you can install the dependencies by running the following command:
vcpkg install eigen3 urdfdom urdfdom-headers lz4 benchmark tbb nlohmann-json FLANN gtest imgui glfw3
You also need to install CUDAToolKit (>=12.6), which you can download from here. OptiX is also required (>=7.7) and can be downloaded from here.
Set up the environment variable for CUDA and configure OptiX_ROOT_DIR.
You can build the project using CMake:
mkdir build
cd build
cmake .. -DCMAKE_TOOLCHAIN_FILE=$PATH_TO_YOUR_VCPKG$/scripts/buildsystems/vcpkg.cmake
This is a demo of the collision checker. You can run it by executing the following commands:
cd build
cmake --build . --target AllDemos --config Release
cd ./bin/Demos/Release # If on Windows
cd ./bin/Demos # If on Linux
# Run any executable here with a name starting with Demo
./demoQuadContinuous.exe # For example
Coming soon. Stay tune!
Coming soon. Stay tune!
All benchmark is carried out in a scene like this. The simple, medium, and dense versions of the scene consisted of over 15k / 22k, 71k / 107k, and 191k / 321k triangles / edges, respectively.
Make sure you run this before you run the curobo benchmark. The RTCD benchmark will generate the poses used for benchmarking.
cd build
cmake --build . --target AllBenchmarks --config Release
cd ..
./benchmark.bat # If on Windows
./benchmark.sh # If on Linux
This will take quite amount of time to run all benchmarks.
We modified the curobo library to disable self-collision and other constraints in order for a fair comparison. To run the curobo benchmark, first install a customized version of curobo here.
The scripts for curobo benchmarking can be found in scripts/Benchmark/curobo
.
We use Moveit Interface for FCL benchmarking. Benchmark setup and source code can be found here.
To plot the result, make sure you run RTCD Benchmarks and Curobo Benchmarks first.
First you need to install julia (>1.10 recommended). And cd scripts
using Pkg
Pkg.activate(.)
# Hit "]", the terminal should start with `(scripts) pkg>`
instantiate # This would install all the required packages for plotting and may take a while.
With the above command, you setup the env. Now back to a bash to plot the results.
julia -O3 ./scripts/Benchmark/plots/discrete/resultAnalysis.jl # For discrete poses benchmark results
julia -O3 ./scripts/Benchmark/plots/curve/resultAnalysisEff.jl # For continuous benchmark results
The plots will be in `./data/Plots/
The code contained herein is of "research grade", meaning it is messy, largely uncommented, insufficently reviewed and optimzied, and intended for reference more than anything else. The authors have tried to make it as "user-friendly" as possible. However, the best we can do now is make it compile and run.
Further development is ongoing. For upcoming features and demos, please refer to the TODO list.
This project is based on the following projects:
- Official OptiX SDK samples shipped with OptiX
- optix7course
This repository was developed at the Human Centered Robotics Lab (HCRL) of The University of Texas at Austin in collaboration with Dexterity, Inc. by Sizhe Sui, advised by Prof. Luis Sentis and Andrew Bylard.
If you found this repository useful, please cite our paper:
- [1] Conference Paper: S Sui, L Sentis, and A Bylard, Hardware-Accelerated Ray Tracing for Discrete and Continuous Collision Detection on GPUs. IEEE International Conference on Robotics and Automation (ICRA) 2025. Available: https://www.arxiv.org/abs/2409.09918