This repository is the official implementations of UTrice: Unifying Primitives in Differentiable Ray Tracing and Rasterization via Triangles for Particle-Based 3D Scenes.
We propose a differentiable triangle-based ray tracing pipeline that treats triangles as primitives without proxy geometry, achieving higher rendering quality while maintaining real-time performance. It also directly renders triangles optimized by Triangle Splatting, unifying the primitives used in novel-view-synthesis.
- This project has been built and tested on Ubuntu 22.04 with Python 3.11 and CUDA 12.6.
- To reproduce our results, we recommend a GPU with 24GB VRAM and Ray Tracing (RT) Cores. We tested on an RTX 4500 Ada and RTX 6000 Ada.
Clone this repository with submodules:
git clone --recursive https://github.com/waizui/UTrice.git
cd UTriceWe use Conda to manage the environments. Please install Conda in advance, then execute the following commands to create and activate an environment.
conda env create -f environment.yaml
conda activate utriceThen install these two modules to finish the installation.
pip install submodules/simple-knn --no-build-isolation
pip install submodules/diff-triangle-tracer --no-build-isolationTo train our model, use the following command:
python train.py -s <path_to_scenes> -m <output_model_path> --evalAdd --outdoor to train on outdoor scenes:
python train.py -s <path_to_scenes> -m <output_model_path> --outdoor --evalTo render a scene, use:
python render.py -m <path_to_model>To evaluate the model, use:
python metrics.py -m <path_to_model>We provide a convinent script to reproduce the results of our paper, to run this scripts, please put all scenes inside a sibiling directory of this project and rename it to datasets. It should look like:
<parent>/
├─ datasets/
│ ├─ bicycle/
│ ├─ garden/
│ └─ ...
└─ <UTrice>/Then, run following command:
python eval_all.pyThe results will be saved in the UTrice/output directory.
The MipNeRF360 scenes are hosted by the paper authors here. You can find SfM datasets for Tanks&Temples and Deep Blending here.
We provide examples of ray tracing effects using --render_mode: dof, reflect, refract, envlight.
python render.py -m <path_to_model> --render_mode <render_mode>@article{liu2025utrice,
title = {UTrice: Unifying Primitives in Differentiable Ray Tracing and Rasterization via Triangles for Particle-Based 3D Scenes},
author = {Changhe Liu and Ehsan Javanmardi and Naren Bao and Alex Orsholits and Manabu Tsukada},
journal = {arXiv},
year = {2025},
}@misc{liu2025utriceunifyingprimitivesdifferentiable,
title={UTrice: Unifying Primitives in Differentiable Ray Tracing and Rasterization via Triangles for Particle-Based 3D Scenes},
author={Changhe Liu and Ehsan Javanmardi and Naren Bao and Alex Orsholits and Manabu Tsukada},
year={2025},
eprint={2512.04421},
archivePrefix={arXiv},
primaryClass={cs.CV},
url={https://arxiv.org/abs/2512.04421},
}

