Convert Figma logo to code with AI

NVIDIAGameWorks logokaolin

A PyTorch Library for Accelerating 3D Deep Learning Research

5,171
628
5,171
29

Top Related Projects

PyTorch3D is FAIR's library of reusable components for deep learning with 3D data

1,953

This is the code for Deformable Neural Radiance Fields, a.k.a. Nerfies.

A Code Release for Mip-NeRF 360, Ref-NeRF, and RawNeRF

Official code for the CVPR 2022 (oral) paper "Extracting Triangular 3D Models, Materials, and Lighting From Images".

code for Mesh R-CNN, ICCV 2019

Calculate signed distance fields for arbitrary meshes

Quick Overview

Kaolin is a PyTorch library for accelerating 3D deep learning research. It provides efficient implementations of differentiable 3D modules for use in deep learning systems. Kaolin aims to make 3D deep learning more accessible and accelerate progress in the field.

Pros

  • Comprehensive set of 3D deep learning tools and primitives
  • Efficient GPU-accelerated implementations
  • Seamless integration with PyTorch ecosystem
  • Active development and support from NVIDIA

Cons

  • Steep learning curve for beginners in 3D deep learning
  • Limited documentation for some advanced features
  • Requires powerful GPU for optimal performance
  • Some features may be unstable or experimental

Code Examples

Loading and visualizing a 3D mesh:

import kaolin as kal
from kaolin.visualize import plot_mesh

mesh = kal.io.obj.import_mesh('path/to/model.obj')
plot_mesh(mesh.vertices, mesh.faces)

Performing differentiable rendering:

import torch
import kaolin as kal

vertices = torch.rand(100, 3)
faces = torch.randint(0, 100, (200, 3))
camera = kal.render.camera.perspective_camera()
render = kal.render.mesh.dibr_rasterization(vertices, faces, camera)

Voxelizing a point cloud:

import torch
import kaolin as kal

points = torch.rand(1000, 3)
voxels = kal.ops.conversions.pointcloud_to_voxelgrid(points, resolution=32)

Getting Started

To get started with Kaolin, follow these steps:

  1. Install Kaolin:

    pip install kaolin
    
  2. Import Kaolin in your Python script:

    import kaolin as kal
    
  3. Load a 3D model and perform operations:

    mesh = kal.io.obj.import_mesh('path/to/model.obj')
    vertices = mesh.vertices
    faces = mesh.faces
    
    # Perform operations on the mesh
    transformed_vertices = kal.ops.mesh.index_vertices_by_faces(vertices, faces)
    

For more detailed information and tutorials, refer to the official Kaolin documentation.

Competitor Comparisons

PyTorch3D is FAIR's library of reusable components for deep learning with 3D data

Pros of PyTorch3D

  • More comprehensive documentation and tutorials
  • Broader range of 3D vision tasks supported
  • Better integration with PyTorch ecosystem

Cons of PyTorch3D

  • Steeper learning curve for beginners
  • Less focus on real-time rendering capabilities

Code Comparison

PyTorch3D:

from pytorch3d.structures import Meshes
from pytorch3d.renderer import MeshRenderer, MeshRasterizer, SoftPhongShader

renderer = MeshRenderer(
    rasterizer=MeshRasterizer(),
    shader=SoftPhongShader()
)

Kaolin:

import kaolin as kal
from kaolin.render.camera import perspective_camera
from kaolin.render.mesh import dibr_rasterization

camera = perspective_camera(...)
faces, attributes = dibr_rasterization(vertices, faces, camera)

Both libraries offer powerful 3D rendering capabilities, but PyTorch3D provides a more abstracted interface, while Kaolin offers more low-level control. PyTorch3D is generally more suitable for research and prototyping, while Kaolin excels in performance-critical applications and game development scenarios.

1,953

This is the code for Deformable Neural Radiance Fields, a.k.a. Nerfies.

Pros of Nerfies

  • Focuses specifically on dynamic scene reconstruction and novel view synthesis
  • Provides a complete implementation of the Nerfies paper, including training and evaluation scripts
  • Offers a user-friendly web interface for visualizing results

Cons of Nerfies

  • Limited to a specific use case (dynamic scene reconstruction)
  • Requires more computational resources for training and inference
  • Less versatile compared to Kaolin's broader 3D deep learning toolkit

Code Comparison

Nerfies (Python):

config = configs.get_config()
model = models.NerfModel(config)
loss = model(batch)

Kaolin (Python):

mesh = kaolin.rep.TriangleMesh.from_obj('model.obj')
renderer = kaolin.render.mesh.dibr.DIBRenderer(camera)
image = renderer(mesh.vertices, mesh.faces)

Summary

Nerfies is a specialized repository for dynamic scene reconstruction, offering a complete implementation of the Nerfies paper with user-friendly visualization tools. Kaolin, on the other hand, is a more comprehensive 3D deep learning library that provides a wide range of tools and utilities for various 3D-related tasks. While Nerfies excels in its specific use case, Kaolin offers greater versatility and broader applicability in 3D deep learning projects.

A Code Release for Mip-NeRF 360, Ref-NeRF, and RawNeRF

Pros of multinerf

  • Focuses specifically on neural radiance fields (NeRF) for 3D scene reconstruction
  • Implements advanced NeRF techniques like mip-NeRF 360 for improved rendering quality
  • Provides pre-trained models and datasets for easy experimentation

Cons of multinerf

  • Limited to NeRF-based techniques, less versatile than Kaolin's broader 3D deep learning toolkit
  • May require more computational resources for training and rendering
  • Less extensive documentation compared to Kaolin's comprehensive guides

Code Comparison

multinerf:

config = config_flags.DEFINE_config_file('config', None, 'Path to the config file.')
FLAGS = flags.FLAGS
render_poses = generate_spiral_path(...)
render_fn = jax.pmap(...)

Kaolin:

import kaolin as kal
mesh = kal.io.obj.import_mesh('model.obj')
voxels = kal.ops.conversions.trianglemeshes_to_voxelgrids(mesh.vertices, mesh.faces)
rendered = kal.render.mesh.dibr_rasterization(mesh.vertices, mesh.faces, camera)

Both repositories offer powerful tools for 3D graphics and deep learning, but they serve different purposes. multinerf specializes in neural radiance fields for scene reconstruction, while Kaolin provides a more comprehensive toolkit for various 3D deep learning tasks.

Official code for the CVPR 2022 (oral) paper "Extracting Triangular 3D Models, Materials, and Lighting From Images".

Pros of nvdiffrec

  • Focused on differentiable rendering and material reconstruction
  • Provides advanced techniques for inverse rendering problems
  • Includes pre-trained models and datasets for quick experimentation

Cons of nvdiffrec

  • More specialized and narrower in scope compared to Kaolin
  • Less comprehensive documentation and tutorials
  • Smaller community and fewer contributors

Code Comparison

nvdiffrec:

import nvdiffrec
renderer = nvdiffrec.Renderer(resolution=(512, 512))
material = nvdiffrec.Material(basecolor_tex=texture)
mesh = nvdiffrec.load_obj('model.obj')
image = renderer.render(mesh, material)

Kaolin:

import kaolin as kal
mesh = kal.io.obj.import_mesh('model.obj')
renderer = kal.render.mesh.rasterize(mesh.vertices, mesh.faces)
texture = kal.render.mesh.texture_mapping(renderer, mesh.uvs, texture)
image = kal.render.camera.perspective_camera(renderer, texture)

Both libraries offer rendering capabilities, but nvdiffrec focuses on differentiable rendering and material reconstruction, while Kaolin provides a broader set of 3D deep learning tools. nvdiffrec is more specialized for inverse rendering problems, while Kaolin offers a more comprehensive suite of 3D-related functionalities.

code for Mesh R-CNN, ICCV 2019

Pros of Mesh R-CNN

  • Focuses specifically on 3D object reconstruction from 2D images
  • Integrates with Detectron2, leveraging its powerful object detection capabilities
  • Provides end-to-end training for mesh prediction tasks

Cons of Mesh R-CNN

  • Limited to mesh reconstruction tasks, less versatile than Kaolin
  • Requires more setup and dependencies due to Detectron2 integration
  • Less active development and community support compared to Kaolin

Code Comparison

Mesh R-CNN:

from detectron2.config import get_cfg
from meshrcnn import add_meshrcnn_config
cfg = get_cfg()
add_meshrcnn_config(cfg)
cfg.merge_from_file("meshrcnn_config.yaml")

Kaolin:

import kaolin as kal
from kaolin.render.camera import perspective_camera
from kaolin.ops.mesh import check_sign
vertices, faces = kal.io.obj.import_mesh('model.obj')

Both libraries offer tools for 3D mesh manipulation, but Kaolin provides a more comprehensive set of utilities for various 3D tasks, while Mesh R-CNN specializes in reconstructing 3D meshes from 2D images using deep learning techniques. Kaolin's broader scope makes it more suitable for general 3D deep learning projects, whereas Mesh R-CNN excels in specific image-to-mesh reconstruction scenarios.

Calculate signed distance fields for arbitrary meshes

Pros of mesh_to_sdf

  • Focused specifically on mesh-to-SDF conversion, making it more lightweight and easier to use for this specific task
  • Provides a simple command-line interface for quick conversions
  • Supports multiple output formats, including NumPy arrays and VDB files

Cons of mesh_to_sdf

  • Limited functionality compared to Kaolin's broader set of 3D deep learning tools
  • Less active development and community support
  • May not integrate as seamlessly with other deep learning frameworks

Code Comparison

mesh_to_sdf:

import mesh_to_sdf
import trimesh

mesh = trimesh.load('model.obj')
points = mesh_to_sdf.sample_sdf_near_surface(mesh, number_of_points=250000)

Kaolin:

import kaolin as kal
import torch

mesh = kal.io.obj.import_mesh('model.obj')
points = kal.ops.mesh.sample_points(mesh.vertices, mesh.faces, num_samples=250000)
sdf = kal.metrics.mesh.signed_distance(mesh.vertices, mesh.faces, points)

Both libraries offer mesh processing capabilities, but Kaolin provides a more comprehensive set of tools for 3D deep learning tasks, while mesh_to_sdf focuses specifically on SDF conversion.

Convert Figma logo designs to code with AI

Visual Copilot

Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.

Try Visual Copilot

README

Kaolin: A PyTorch Library for Accelerating 3D Deep Learning Research

TL;DR — Kaolin is NVIDIA's PyTorch library of reusable, GPU-optimized modules distilled from 3D deep learning research.

  • Representation-agnostic physics (meshes, splats, point clouds) with Simplicits
  • Differentiable rendering (DIB-R, nvdiffrast, easy_render PBR)
  • First-class 3D Gaussian splats (PLY/USD I/O, densification, gsplat bridge)
  • GPU octree acceleration structure: Structured Point Clouds (SPC)
  • Conversions between 3D representations, quaternion ops, and USD I/O

Kaolin Physics simulation with Kaolin

Documentation Version License NVIDIA Kaolin

Kaolin packages reusable building blocks from NVIDIA 3D research into a cohesive PyTorch API — continuously improving representation-agnostic physics simulation, fast conversions between representations, quaternion math, batched mesh and splat containers, I/O, visualization and more. See kaolin.readthedocs.io for tutorials and API reference, and developer.nvidia.com/kaolin for the NVIDIA Kaolin hub.

SIGGRAPH 2026

Join us in Los Angeles! Two sessions showcasing new Kaolin capabilities. Full details here.

Web framework talk

Talk — Any Representation, Any Hardware, All Interactions

Accelerating Interactive Prototypes Over Cutting Edge AI & 3D Research

Sun 19 Jul 2026, 3:00–3:20 pm PDT · Room 408 A

Maria Shugrina (NVIDIA / University of Toronto)

Introduces Kaolin's new web client-server framework (kaolin/visualize/dash) for rapid prototyping of interactive browser interfaces over emerging AI and 3D research — patterns distilled from building interactive tools at SIGGRAPH technical papers, Real-Time Live, and Labs. Available on the web_framework_prerelease branch (not yet merged to master).

Schedule →

Capture to simulation lab

Hands-on Lab — From 3D Captures to Simulated Digital Environments

Thu 23 Jul 2026, 10:15–11:45 am PDT · Concourse Hall

Clement Fuji Tsang, Vismay Modi, Maria Shugrina (NVIDIA)

A capture-to-simulation pipeline for in-the-wild 3D Gaussian Splat scenes: segment objects, predict volumetric mechanical properties, run mixed splat–mesh physics — powered by recent Kaolin features. Export shareable USD files with Kaolin's custom physics schema.

Bring your laptop and follow along hands-on. Full Conference badge required.

Schedule →

Features

Physics (Simplicits)

Simulate meshes, splats, and point clouds with collisions. Warp-accelerated, representation-agnostic.

Docs · Mesh · Splat · 3DGRUT

3D Gaussian Splats

GaussianSplatModel, PLY/USD I/O, densification, gsplat camera converters.

Tutorial · Simulate · Interactive viz

Differentiable Rendering

DIB-R, nvdiffrast, easy_render PBR, spherical harmonics and spherical gaussians lighting.

Docs · DIB-R · Easy render · Camera · Lighting

Structured Point Clouds

GPU octree acceleration structure with ray tracing and feature grids.

Docs · Tutorial · API

USD Pipeline

Import/export meshes, point clouds, gaussians, and physics materials with Kaolin's custom schema.

API · Checkpoints · GLTF viz

Visualization

Jupyter 3D viewer, Timelapse checkpoints, and web client-server framework.

Docs · Interactive · Checkpoints · Web framework branch

Conversions

Fast GPU conversions between meshes, voxel grids, point clouds, gaussians, and more.

Docs · DMTet · FlexiCubes

Quaternions

Differentiable quaternion and rigid-transform utilities for 3D deep learning.

Docs · Tutorial · API

Surface Meshes

Batched SurfaceMesh container with auto-computed attributes and I/O.

Docs · Tutorial · Easy render

Experimental: Newton coupling — Simplicits soft bodies with rigid bodies, MPM, and articulated robots (rigid · MPM · Franka).

See the tutorial index and API reference at kaolin.readthedocs.io.

Installation

Starting with v0.12.0, Kaolin supports installation with pre-built wheels:

# Replace TORCH_VERSION and CUDA_VERSION with your torch / cuda versions
pip install kaolin==0.18.0 -f https://nvidia-kaolin.s3.us-east-2.amazonaws.com/torch-{TORCH_VERSION}_cu{CUDA_VERSION}.html

For example, kaolin 0.18.0 with PyTorch 2.8.0 and CUDA 12.8:

pip install kaolin==0.18.0 -f https://nvidia-kaolin.s3.us-east-2.amazonaws.com/torch-2.8.0_cu128.html

See the installation guide for the full torch/CUDA compatibility matrix and source install instructions.

python -c "import kaolin; print(kaolin.__version__)"

Quickstart

import kaolin
print(kaolin.__version__)

Load a 3D Gaussian splat from PLY or USD:

import kaolin
from kaolin.rep import GaussianSplatModel

gs = kaolin.io.import_gaussiancloud("scene.ply")
print(gs)  # GaussianSplatModel with positions, scales, rotations, opacities, ...

Simulate a mesh with Simplicits — see the physics tutorial.

Render a mesh with the easy PBR API:

import kaolin as kal

mesh = kal.io.obj.import_mesh("model.obj")
camera = kal.render.easy_render.default_camera(512)
lighting = kal.render.easy_render.default_lighting()
result = kal.render.easy_render.render_mesh(camera, mesh, lighting=lighting)

News

Unreleased (master or staging)

Recent work on master since v0.18.0:

  • FreeForm / RKPM (CVPR 2026) — mesh-free, reduced-order deformable simulation for meshes and Gaussian splats. Builds skinning eigenmodes with a Reproducing Kernel Particle Method (RKPM) basis instead of per-shape neural-field optimization — about 40× faster training and lower error vs. FEM. Now integrated in Kaolin Simplicits.
  • Web client-server framework (kaolin/visualize/dash) — rapid prototyping of interactive Web UIs over AI and 3D research (web_framework_prerelease branch; SIGGRAPH 2026 talk)
  • GaussianSplatModel and PointSamples tensor-container API
  • PLY/USD gaussian I/O with feature preservation
  • USD physics schema — materials, skinned physics, subset features
  • gsplat batched camera converters
  • Newton coupling — soft bodies with rigid/MPM/Franka (notebooks)
  • Simplicits Easy API save/load redesign and collision friction fixes
  • FlexiCubes now Apache 2.0 at kaolin/ops/conversions/flexicubes/

v0.18.0 highlights

See release notes for details.

Tutorials

Notebooks live under examples/tutorial/. Highlights by topic:

Physics

Gaussians

Rendering

Structured Point Clouds

Visualization

Full index: tutorial index.

Ecosystem

Projects built with Kaolin:

  • FreeForm / RKPM — mesh-free reduced-order simulation via RKPM skinning eigenmodes (CVPR 2026)
  • VoMP — feed-forward volumetric mechanical property fields for splats, meshes, and NeRFs (ICLR 2026)
  • ArtisanGS — interactive Gaussian splat selection and segmentation with AI + human in the loop
  • TRON — relightable 3D Gaussian reconstructions with a single-step neural renderer
  • 3DGRUT — ray tracing and hybrid rasterization of Gaussian particles
  • 3DGUT — joint mesh and Gaussian splat rendering (CVPR 2025 oral)
  • Diffusion Texture Painting — interactive diffusion-based texture painting on 3D meshes (SIGGRAPH 2024)
  • NVIDIA Kaolin Wisp — neural fields engine (NeRF, NGLOD, instant-ngp)
  • gsplat — CUDA Gaussian splatting with Kaolin camera bridge
  • NVIDIA Newton — physics engine with experimental Kaolin coupling
  • Neural Geometric LOD (nglod) — SPC ray tracing
  • FlexiCubes — gradient-based mesh extraction (SIGGRAPH 2023)
  • DefTet — deformable tetrahedral mesh reconstruction
  • DIB-R — single-image 3D reconstruction
  • gradSim — differentiable simulation
  • Text2Mesh — text-driven mesh stylization

Contributing

Please review our contribution guidelines.

License

Kaolin is released under the Apache License 2.0. A default import kaolin gives you the full Apache-licensed library.

The kaolin/non_commercial/ package is legacy only — kept for backward compatibility with older import paths (e.g. the pre-Apache FlexiCubes copy). New code should use the Apache-licensed modules under kaolin/ops/, kaolin/rep/, and the rest of the package tree.

Citation

If you use Kaolin in your research, please cite:

@software{KaolinLibrary,
  author  = {Tsang, Clement Fuji and Shugrina, Maria and Lafleche, Jean-Francois and Perel, Or and Loop, Charles and Takikawa, Towaki and Modi, Vismay and Zook, Alexander and Wang, Jiehan and Chen, Wenzheng and Shen, Tianchang and Gao, Jun and Jatavallabhula, Krishna Murthy and Smith, Edward and Rozantsev, Artem and Fidler, Sanja and State, Gavriel and Gorski, Jason and Xiang, Tommy and Li, Jianing and Li, Michael and Lebaredian, Rev},
  title   = {{Kaolin: A PyTorch Library for Accelerating 3D Deep Learning Research}},
  version = {0.18.0},
  date    = {2024-11-20},
  url     = {https://github.com/NVIDIAGameWorks/kaolin}
}

Contributors

Current team: Clement Fuji Tsang (Technical Lead), Maria (Masha) Shugrina (Manager), Charles Loop, Vismay Modi, Or Perel

Other major contributors: Alexander Zook, Donglai Xiang, Wenzheng Chen, Sanja Fidler, Jun Gao, Jason Gorski, Jean-Francois Lafleche, Rev Lebaredian, Jianing Li, Michael Li, Krishna Murthy Jatavallabhula, Artem Rozantsev, Tianchang (Frank) Shen, Edward Smith, Gavriel State, Towaki Takikawa, Jiehan Wang, Tommy Xiang