Fine-Tuning 3D Generation Models with TRELLIS.2
This article explains how to fine-tune 3D generation models using LoRA adapters based on a guide published by Hugging Face.
Fine-Tuning 3D Generation Models with TRELLIS.2
How Targeted Component Adaptation Works
According to Hugging Face, fine-tuning is applied exclusively to the sparse-structure flow Diffusion Transformer (DiT) and the shape flow DiT. The texture flow DiT and backbone weights are frozen.
- Reported Fact: This approach updates roughly 9.3 million adapter parameters total using LoRA adapters.
- Developer Interpretation: By freezing the texture generation stage, this design preserves pretrained priors and prevents catastrophic forgetting while significantly reducing memory overhead during training.
Practical Implementation: The Footwear Dataset Pipeline
To understand how data flows into the model, consider the dataset preprocessing workflow reported in the source.
- Reported Fact: The workflow utilized 188 footwear objects from a subset of the Google Scanned Objects (GSO) dataset, allocating 179 for training and 9 for evaluation. Blender rendered 16 views per object as conditioning images, and encoders converted meshes into TRELLIS.2 latent representations ahead of time.
- Concrete Example: If a developer prepares a custom dataset, pre-encoding the meshes into latent representations allows multiple training runs to reuse the dataset immediately without re-encoding the original 3D meshes on every iteration.
Training runs themselves use a rectified flow-matching objective with PyTorch bfloat16 autocasting, fp32 master weights for LoRA parameters, gradient accumulation, and gradient checkpointing. Execution typically occurs via Docker containers or Hugging Face Jobs on 80 GB A100 GPUs, with metrics monitored through a Trackio dashboard.
Quantitative Performance Gains
Hugging Face reports specific performance improvements when evaluating the model on the nine held-out test objects.
- Reported Fact: The fine-tuned footwear model achieved a mean F-score @ 0.02 of 0.803 (compared to 0.276 for the base model), a reduced Chamfer distance of 0.033 (down from 0.174), and an increased normal consistency of 0.804 (up from 0.530).
- Developer Interpretation: These metrics demonstrate that targeted adapter updates can correct specific structural failures—such as misgenerated footwear soles—that appear when using an unmodified pretrained model.
Known Limitations
Developers should consider several hardware and structural constraints before beginning a fine-tuning run:
- Omission of Material Fine-Tuning: The texture flow DiT is kept frozen because the training dataset lacks true material maps and instead uses diffuse color maps with baked lighting. According to the source, attempting to fine-tune this stage without proper maps risks baking lighting details directly into surface properties.
- Loss Metric Ambiguity: Training loss curves vary based on sampled objects, noise, and timesteps. The source notes that these curves do not reliably measure final geometric quality on their own, requiring validation against held-out test objects.
- Hardware and Access Dependencies: The setup process requires high-end infrastructure, such as an 80 GB A100 GPU for efficient latent training, alongside specific access credentials like a gated Hugging Face account for DINOv3 and a valid
HF_TOKEN.
For full implementation details, read the complete Hugging Face Blog Post.