Skip to content
On this page

Last updated:

CUDA RL Path Tracing

Reinforcement Learning based Path Tracer in CUDA (Research Project)

Github https://github.com/repalash/CUDAPathTracerRL

Monte Carlo based path tracer with both CPU(with openMP) and GPU support(with CUDA).

CUDA based renderer optionally uses Reinforcement Learning (based on ideas from NVIDIA paper: Learning Light Transport the reinforced way).

RL assumes that every ray has 8 actions available to choose from in each bounce(based on the 8 octants). So a QTable is built upon that and the most optimum path is chosen. With time, the rays learn the best path to take to reach the light source. Since this is online Reinforcement Learning, there is no training period and the values converge pretty fast.

Renders

Render 1Render 1Render 1Render 1

CPU vs GPU comparision(no RL)

CPU vs GPU

Path tracing with Reinforcement learning on GPU

RL vs GPURL vs GPU working

We can see here that in the same time, the rays were able to find a better path for indirect lighting, hence better illumination.

More comparisions

RL vs GPURL vs GPURL vs GPU

Issues with RL based lighting

RL issues

Made with ❤️ using the awesome vitepress