Awaiting GPU grant

Image to 3D with TRELLIS.2-4B

A 4B-parameter flow-matching transformer that turns a single image into a textured 3D asset with real PBR materials — including transparency and non-manifold topology.

Model card Official demo Paper Code

Why this page has no demo

The app is complete and lives in this repository (app.py plus the vendored trellis2/ library). It is hosted statically because this is a new Hugging Face account, and free ZeroGPU access requires an account at least 30 days old.

TRELLIS.2-4B needs an NVIDIA GPU with 24 GB VRAM minimum — there is no CPU path, and the CUDA extensions (o_voxel, nvdiffrast, flex_gemm) are built for Blackwell sm_120 only. A GPU community grant has been requested; the Space switches to sdk: gradio and goes live the moment it is approved. No code change needed.

How the app works

  1. Image Prompt — upload or paste an image, or click an example. A transparent PNG works best; otherwise the foreground is segmented out automatically.
  2. Resolution — 512 fastest, 1024 default, 1536 most detailed.
  3. Generate — three-stage sampler (sparse structure → shape latent → material latent), returns a turntable preview you can switch between normal / clay / base colour / HDR-lit materials.
  4. Extract GLB — decodes to a textured mesh, remeshes, bakes the PBR texture, and gives you a downloadable .glb.

What makes TRELLIS.2 different

Most 3D generators are built on iso-surface fields (SDF, Flexicubes), which struggle with open surfaces and non-manifold geometry. TRELLIS.2 uses O-Voxels — a sparse, field-free voxel structure that encodes geometry and appearance together, with instant bidirectional conversion to and from meshes.

Based on the official microsoft/TRELLIS.2 Space · MIT licensed · microsoft/TRELLIS.2