A high-performance C++ and CUDA implementation of 3D Gaussian Splatting
Quick Start • Installation • Usage • Results • Community
LichtFeld Studio is a high-performance implementation of 3D Gaussian Splatting that leverages modern C++23 and CUDA 12.8+ for optimal performance. Built with a modular architecture, it provides both training and real-time visualization capabilities for neural rendering research and applications.
- 2.4x faster rasterization (winner of first bounty by Florian Hahlbohm)
- MCMC optimization strategy for improved convergence
- Real-time interactive viewer with OpenGL rendering
- Modular architecture with separate core, training, and rendering components
- Multiple rendering modes including RGB, depth, and combined views
- Bilateral grid appearance modeling for handling per-image variations
Join our growing community for discussions, support, and updates:
- Discord Community - Get help, share results, and discuss development
- Website - Visit our website for more resources
- Awesome 3D Gaussian Splatting - Comprehensive paper list
- @janusch_patas - Follow for the latest updates
$2,600 + $500 Bonus Challenge
Details: Issue #284
Previous winner: Florian Hahlbohm (2.4x rasterizer speedup)
# Clone and build (Linux)
git clone https://github.com/MrNeRF/LichtFeld-Studio
cd LichtFeld-Studio
# Download LibTorch
wget https://download.pytorch.org/libtorch/cu128/libtorch-cxx11-abi-shared-with-deps-2.7.0%2Bcu128.zip
unzip libtorch-cxx11-abi-shared-with-deps-2.7.0+cu128.zip -d external/
# Build
cmake -B build -DCMAKE_BUILD_TYPE=Release -G Ninja
cmake --build build -- -j$(nproc)
# Train on sample data
./build/gaussian_splatting_cuda -d data/garden -o output/garden --eval-
OS: Linux (Ubuntu 22.04+) or Windows
-
CMake: 3.30 or higher
-
Compiler: C++23 compatible (GCC 14+ or Clang 17+)
-
CUDA: 12.8 or higher (required)
-
LibTorch: 2.7.0 (setup instructions below)
-
vcpkg: For dependency management
- GPU: NVIDIA GPU with compute capability 7.5+
- VRAM: Minimum 8GB recommended
- Tested GPUs: RTX 4090, RTX A5000, RTX 3090Ti, A100, RTX 2060 SUPER
Linux Build
# Set up vcpkg (one-time setup)
git clone https://github.com/microsoft/vcpkg.git
cd vcpkg && ./bootstrap-vcpkg.sh -disableMetrics && cd ..
## If you want you can specify vcpkg locally without globally setting env variable (see -DCMAKE_TOOLCHAIN_FILE version)
export VCPKG_ROOT=/path/to/vcpkg # Add to ~/.bashrc
# Clone repository
git clone https://github.com/MrNeRF/LichtFeld-Studio
cd LichtFeld-Studio
# Download LibTorch 2.7.0 with CUDA 12.8
wget https://download.pytorch.org/libtorch/cu128/libtorch-cxx11-abi-shared-with-deps-2.7.0%2Bcu128.zip
unzip libtorch-cxx11-abi-shared-with-deps-2.7.0+cu128.zip -d external/
rm libtorch-cxx11-abi-shared-with-deps-2.7.0+cu128.zip
# Build
cmake -B build -DCMAKE_BUILD_TYPE=Release -G Ninja
## Or if you want you can specify your own vcpkg
# cmake -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE="<path-to-vcpkg>/scripts/buildsystems/vcpkg.cmake" -G Ninja
cmake --build build -- -j$(nproc)Windows Build
note: Detailed instructions here
Run in x64 native tools command prompt for VS:
# Set up vcpkg (one-time setup)
git clone https://github.com/microsoft/vcpkg.git
cd vcpkg && .\bootstrap-vcpkg.bat -disableMetrics && cd ..
## If you want you can specify vcpkg locally without globally setting env variable (see -DCMAKE_TOOLCHAIN_FILE version)
set VCPKG_ROOT=%CD%\vcpkg
# Clone repository
git clone https://github.com/MrNeRF/LichtFeld-Studio
cd LichtFeld-Studio
# Create directories
if not exist external mkdir external
if not exist external\debug mkdir external\debug
if not exist external\release mkdir external\release
# Download LibTorch (Debug)
curl -L -o libtorch-debug.zip https://download.pytorch.org/libtorch/cu128/libtorch-win-shared-with-deps-debug-2.7.0%2Bcu128.zip
tar -xf libtorch-debug.zip -C external\debug
del libtorch-debug.zip
# Download LibTorch (Release)
curl -L -o libtorch-release.zip https://download.pytorch.org/libtorch/cu128/libtorch-win-shared-with-deps-2.7.0%2Bcu128.zip
tar -xf libtorch-release.zip -C external\release
del libtorch-release.zip
# Build
## Or if you want you can specify your own vcpkg
# cmake -B build -DCMAKE_BUILD_TYPE=Release -G ninja -DCMAKE_TOOLCHAIN_FILE="<path-to-vcpkg>/scripts/buildsystems/vcpkg.cmake"
# Ninja should be included with Visual Studio installation,
# if not you can either install it,
# or ignore this flag and use native generator - Building time might be extended
cmake -B build -DCMAKE_BUILD_TYPE=Release -G Ninja
cmake --build build -jDocker Build
# Build and start container
./docker/run_docker.sh -bu 12.8.0
# Build without cache
./docker/run_docker.sh -n
# Stop containers
./docker/run_docker.sh -cUbuntu 24.04+ (GCC 14)
# Install GCC 14
sudo apt update
sudo apt install gcc-14 g++-14 gfortran-14
# Set as default
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-14 60
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-14 60
sudo update-alternatives --config gcc
sudo update-alternatives --config g++Ubuntu 22.04 (Build GCC 14 from source)
# Install dependencies
sudo apt install build-essential libmpfr-dev libgmp3-dev libmpc-dev -y
# Download and build GCC
wget http://ftp.gnu.org/gnu/gcc/gcc-14.1.0/gcc-14.1.0.tar.gz
tar -xf gcc-14.1.0.tar.gz
cd gcc-14.1.0
# Configure and build (1-2 hours)
./configure --prefix=/usr/local/gcc-14.1.0 --enable-languages=c,c++ --disable-multilib
make -j$(nproc)
sudo make install
# Set up alternatives
sudo update-alternatives --install /usr/bin/gcc gcc /usr/local/gcc-14.1.0/bin/gcc 14
sudo update-alternatives --install /usr/bin/g++ g++ /usr/local/gcc-14.1.0/bin/g++ 14Download and extract the Tanks & Trains dataset:
wget https://repo-sam.inria.fr/fungraph/3d-gaussian-splatting/datasets/input/tandt_db.zip
unzip tandt_db.zip -d data/Basic training:
./build/gaussian_splatting_cuda -d data/garden -o output/gardenTraining with evaluation and visualization:
./build/gaussian_splatting_cuda \
-d data/garden \
-o output/garden \
--eval \
--save-eval-images \
--render-mode RGB_D \
-i 30000MCMC strategy with limited Gaussians:
./build/gaussian_splatting_cuda \
-d data/garden \
-o output/garden \
--strategy mcmc \
--max-cap 500000-d, --data-path [PATH]- Path to training data with COLMAP reconstruction
-o, --output-path [PATH]- Output directory (default:./output)-i, --iter [NUM]- Training iterations (default: 30000)-r, --resize_factor [NUM]- Image resolution factor (default: 1)--strategy [mcmc|default]- Optimization strategy (default:mcmc)--max-cap [NUM]- Maximum Gaussians for MCMC (default: 1000000)
--eval- Enable evaluation during training--save-eval-images- Save evaluation images--test-every [NUM]- Test/validation split ratio (default: 8)
--headless- Run without GUI (terminal-only mode)
--bilateral-grid- Enable appearance modeling--steps-scaler [NUM]- Scale training steps for multiple checkpoints- See
--helpfor complete list of options
The implementation uses weights/lpips_vgg.pt, exported from torchmetrics with:
- Network: VGG with ImageNet pretrained weights
- Input range: [-1, 1] (conversion handled internally)
- Normalization: Included in model
LichtFeld-Studio/
├── src/
│ ├── core/ # Foundation (data structures, utilities)
│ ├── geometry/ # Geometric operations
│ ├── loader/ # Dataset loading (COLMAP, PLY, Blender)
│ ├── training/ # Training pipeline and strategies
│ ├── rendering/ # CUDA/OpenGL rendering
│ └── visualizer/ # Interactive GUI
├── gsplat/ # Optimized rasterization backend
├── fastgs/ # Fast Gaussian splatting kernels
└── parameter/ # JSON configuration files
We welcome contributions! See our Contributing Guidelines.
- Check issues labeled good first issue
- Join our Discord for discussions
- Use the pre-commit hook:
cp tools/pre-commit .git/hooks/
- C++23 compatible compiler (GCC 14+ or Clang 17+)
- CUDA 12.8+ for GPU development
- Apply
clang-formatfor code style
This implementation builds upon:
- gsplat - Optimized CUDA rasterization backend
- 3D Gaussian Splatting - Original work by Kerbl et al.
@software{lichtfeld2025,
author = {LichtFeld Studio},
title = {A high-performance C++ and CUDA implementation of 3D Gaussian Splatting},
year = {2025},
url = {https://github.com/MrNeRF/gaussian-splatting-cuda}
}This project is licensed under GPLv3. See LICENSE for details.