Vi3W
Skip to content

Guides

TRELLIS local install: run Microsoft's TRELLIS and TRELLIS 2 on your own GPU

TRELLIS local install guide: requirements, setup.sh commands for TRELLIS and TRELLIS 2, the web demo, Windows and low-VRAM options, and fixes.

2 min read

A potted plant model assembling from small glowing cubes above a graphics card on a desk
Illustration. TRELLIS builds shapes from structured 3D latents.

Quick answer

How do I run TRELLIS locally?

On Linux with an NVIDIA GPU: clone the repo with submodules, run its setup.sh with a new conda environment, then run app.py for the web demo. TRELLIS needs at least 16 GB of VRAM and TRELLIS 2 at least 24 GB. Both are MIT-licensed. On Windows, community ComfyUI workflows, including low-VRAM ones, are the common route.

Requirements (from Microsoft's READMEs)

TRELLIS (microsoft/TRELLIS, MIT)

  • Linux (tested); Windows "not fully tested".
  • NVIDIA GPU with at least 16 GB; verified on A100 and A6000.
  • CUDA Toolkit (tested with 11.8 and 12.2), Python 3.8+, conda recommended.
  • Models: TRELLIS-image-large (1.2B) plus text models from 342M to 2.0B.

TRELLIS 2 (microsoft/TRELLIS.2, MIT)

  • Linux (tested).
  • NVIDIA GPU with at least 24 GB; verified on A100 and H100.
  • CUDA 12.4 recommended. Model: TRELLIS.2-4B.
Video: Microsoft TRELLIS.2 - High-Fidelity Image-to-3D with AI: Hands-on Local Demo, by Fahd Mirza (YouTube)

Install TRELLIS

  1. git clone --recurse-submodules https://github.com/microsoft/TRELLIS.git and cd TRELLIS
  2. Create the environment and build extensions with the README's command: . ./setup.sh --new-env --basic --xformers --flash-attn --diffoctreerast --spconv --mipgaussian --kaolin --nvdiffrast
  3. For the web demo: . ./setup.sh --demo, then python app.py.

Weights download from Hugging Face (microsoft/TRELLIS-image-large) on first use.

Install TRELLIS 2

  1. git clone -b main https://github.com/microsoft/TRELLIS.2.git --recursive and cd TRELLIS.2
  2. . ./setup.sh --new-env --basic --flash-attn --nvdiffrast --nvdiffrec --cumesh --o-voxel --flexgemm
  3. python app.py for the demo.

If you have several CUDA toolkits installed, the README says to set CUDA_HOME to the right one first.

A plant assembling from glowing cubes above a graphics card
Illustration. More VRAM means larger models and higher-resolution output.

Windows and smaller GPUs

  • ComfyUI: community node packs and workflows exist for both, including GGUF and low-VRAM variants. See TRELLIS 2 in ComfyUI.
  • Hugging Face demos: Microsoft links live demos for both models.

Community low-VRAM workflows trade quality or speed for memory; results vary.

Common install errors

  • Extension compile failures: CUDA toolkit and PyTorch CUDA must match.
  • flash-attn won't build: check your GPU architecture and versions; the README's --xformers option is an alternative for TRELLIS.
  • Out of memory: close other GPU apps; lower resolution settings.

After generation

Export GLB and import into Blender (File ‣ Import ‣ glTF 2.0), then decimate or retopologise. See Blender auto retopology.

TRELLIS without the install

TRELLIS is Vi3W's free default model, and TRELLIS 2 is on paid plans, in the browser with no GPU. Results can be retopologised and exported as GLB, FBX or OBJ. Try Vi3W.

Deciding between open models? Read Hunyuan3D vs TRELLIS 2.

Frequently asked questions

trellis local install

git clone --recurse-submodules the TRELLIS repo, then run setup.sh with --new-env and the extension flags listed in the README, then python app.py. TRELLIS 2 follows the same pattern with its own flags.

trellis 2 local install

Clone microsoft/TRELLIS.2 recursively, run its setup.sh (it creates a trellis2 conda environment), and run app.py. Its README asks for a 24 GB NVIDIA GPU and CUDA 12.4.

run trellis locally

Linux plus NVIDIA is the tested path. On Windows, use ComfyUI nodes or community guides; Windows support for the original TRELLIS is listed as not fully tested.

Last reviewed