← all repositories
hiroharu-kato/neural_renderer

Differentiable 3D renderer that backpropagates through pixels

A CVPR 2018 renderer that lets you optimize meshes, textures, and camera poses via gradient descent.

1.2k stars Python Computer Vision
neural_renderer
Velocity · 7d
+0.4
★ / day
Trend
steady
star history

What it does This is a 3D mesh renderer with a twist: it’s fully differentiable. You can render a triangle mesh to a 2D image, compute a loss against some target, and backpropagate that loss all the way back to the vertices, textures, or camera parameters. The repo ships with four examples—multi-view rendering, silhouette morphing, texture matching, and camera pose recovery—plus pointers to downstream projects that do full mesh reconstruction and 3D DeepDream.

The interesting bit The authors implemented this in Chainer back in 2018, when “differentiable rendering” was still a novelty. The trick is computing derivatives of the rendered image with respect to the 3D scene parameters, which lets you treat rasterization as just another layer in a neural network. No ray tracing, no neural approximations—just classical graphics made gradient-friendly.

Key highlights

  • Core renderer + four self-contained examples (vertices, textures, camera pose, multi-view)
  • Downstream repos linked: single-image mesh reconstruction, 2D-to-3D style transfer, 3D DeepDream
  • Two PyTorch ports available: a wrapper by Kanazawa & Tulsiani, and a standalone re-implementation by Kolotouros
  • GPU-only; authors explicitly decline to support CPU because “it would be probably too slow”
  • Python 2.x only; Python 3 users are directed to the PyTorch ports

Caveats

  • No CPU fallback, and no plans for one
  • Python 2.x codebase; running under Python 3 is officially untested and not recommended
  • “This repository only contains the core component and simple examples”—you’ll need to stitch it into something larger for real work

Verdict Worth a look if you’re doing differentiable rendering research or need a reference implementation to compare against. If you just want a modern, maintained renderer for a PyTorch pipeline, skip this and grab one of the linked ports instead.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.