Implementation of code for Discontinuity-Aware 2D Neural Fields (SIGGRAPH Asia 2023, Transactions on Graphics) website, paper, slides PDF.
This code is a re-implementation of the paper using SLANG and PyTorch. As such, the results may not exactly match the original implementation.
Using this code, you can (qualitatively) reproduce a few examples from the paper:
- Flowerpot scene (Fig. 9) -- Rendering
- Circles scene (Fig. 10) -- Walk on Spheres
- Shapes scene (Fig. 2) -- Vector Graphics
Install pytorch and diffvg (with python bindings).
pip install scikit-image numpy matplotlib slangpy svgpathtools pillow
Download the data from here and place it in the root directory.
To run the circles scene: python train.py circles and similarly for shapes, flowerpot.
Results will be generated in the results directory.
Note: the first time you run this, there might be some delay (2-3 mins) while SLANG compiles some kernels.
- Mesh compression using draco.
- Data preparation for custom scenes, a> modified version of TriWild and b> edge extraction for rendering scenes.
@article{Belhe:2023:DiscontinuityAwareNeuralFields,
author = {Yash Belhe and Micha\"{e}l Gharbi and Matthew Fisher and Iliyan Georgiev and Ravi Ramamoorthi and Tzu-Mao Li},
title = {Discontinuity-aware 2D neural fields},
journal = {ACM Transactions on Graphics (Proceedings of SIGGRAPH Asia)},
year = {2023},
volume = {41},
number = {6},
doi = {10.1145/3550454.3555484}
}