A fast path tracing renderer
Project description
Path Tracing (WIP)
A path tracing renderer in Python accelerated by OpenMP & CUDA.
100,000 spp (1.5 min) | 50,000 spp (21 min) |
Getting Started
First of all, clone the repo recursively to your local environment.
git clone --recursive https://github.com/li-plus/path-tracing.git && cd path-tracing
If you miss the --recursive
argument, you could still fetch the submodules in this way.
git clone https://github.com/li-plus/path-tracing.git && cd path-tracing
git submodule update --init
Python API
Install the python package from source.
sudo apt install gcc g++ cmake libeigen3-dev python3-dev python3-pip
pip install .
Run the Python example.
cd examples/python
python3 main.py --device cuda --num-samples 1000 --save-path scene.png --scene cornell_box
C++ API
C++ API is not yet stable. Please consider using Python API instead for the time being.
Install dependencies needed to build the C++ example.
sudo apt install gcc g++ cmake libeigen3-dev libopencv-dev libgflags-dev
Build the path tracing library and the C++ example.
mkdir -p build && cd build
cmake .. && make -j
Run the C++ example.
./bin/pt -device cuda -num_samples 1000 -save_path scene.png -scene cornell_box
Docker
For those who do not have root privilege, we offer an alternative to build & run path tracing within a docker container. For GPU support, nvidia-docker should be further installed.
Build a docker image with everything installed for development.
docker build ./docker -t pt:latest
Start a docker container, with project directory mapped to /opt/path-tracing
.
docker run -it --rm --runtime nvidia -v $PWD:/opt/path-tracing -w /opt/path-tracing pt:latest bash
References
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file path-tracing-0.0.1.tar.gz
.
File metadata
- Download URL: path-tracing-0.0.1.tar.gz
- Upload date:
- Size: 1.7 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.24.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.8.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6770dddb8d764933aa5459ecb2ba10bc37fb7a9e1964756f321b78739ae32de6 |
|
MD5 | 3c8c230d80efe424ab5251a5c259477d |
|
BLAKE2b-256 | b33c42ae39b1f12e83ea0452ab89b37e6a23412ed14581b44d71e12397612200 |