在本页阅读需 8 分钟
概述
Its key idea, Score Distillation Sampling (SDS), uses a frozen 2D text-to-image diffusion model as a critic that grades rendered views of a 3D scene and pushes the scene toward what the prompt describes. SDS became the foundation of most optimization-based text-to-3D research.
主要要点
- DreamFusion, from Google Research in 2022, generates 3D objects from text using only a pretrained 2D image diffusion model.
- Score Distillation Sampling compares a diffusion model's predicted noise with the true noise on a rendering and pushes that difference into the 3D model.
- The frozen diffusion model acts as a critic; gradients never flow through it, which keeps each update cheap.
- DreamFusion used a classifier-free guidance weight of 100 and took about 1.5 hours per object on four TPUv4 chips.
- SDS results tend to be oversaturated, oversmoothed and low in diversity, which later methods such as ProlificDreamer set out to fix.
- DreamFusion received an Outstanding Paper Award at ICLR 2023.
深入探讨
DreamFusion turns a sentence such as 'a squirrel playing a guitar' into a 3D model that can be viewed from any angle, relit and placed in a scene. It was introduced in 'DreamFusion: Text-to-3D using 2D Diffusion' by Ben Poole, Ajay Jain, Jonathan T. Barron and Ben Mildenhall of Google Research and UC Berkeley, posted to arXiv on 29 September 2022. The paper won an Outstanding Paper Award at ICLR 2023. Its central contribution is a loss function called Score Distillation Sampling, or SDS, which lets a pretrained image generator supervise the creation of something it was never trained to make.
The problem it solved was data. Text-to-image diffusion models learned from billions of captioned images, but no comparable collection of captioned 3D models existed, and the authors note that efficient architectures for denoising 3D data were also lacking. Earlier text-to-3D work such as Dream Fields used CLIP, a model that scores how well an image matches a caption, to guide a 3D scene, but its results tended to lack realism. DreamFusion kept the same overall recipe, optimizing a 3D scene so its 2D renderings look right, and swapped CLIP for a diffusion model.
The 3D scene is a Neural Radiance Field, or NeRF: a small neural network that takes a 3D point and returns a density (how opaque the space is) and a color. Images are made by volume rendering, shooting rays from a virtual camera and accumulating density and color along each ray. DreamFusion builds on mip-NeRF 360, a variant that reduces aliasing. Rather than raw color, it predicts albedo, the surface's base color, and computes surface normals from the density field so the object can be shaded under a light source. This matters because shading exposes the true shape.
Each optimization step runs as follows. Sample a random camera position around the object and a random light direction. Render an image of the current NeRF, sometimes with full color and shading, sometimes as plain albedo, and sometimes as a 'textureless' gray shaded render that shows geometry alone. Add Gaussian noise to that image at a random noise level. Ask the frozen diffusion model, given the noisy image and the prompt, to predict the noise. Take the difference between predicted and actual noise as the update direction, and backpropagate it through the renderer into the NeRF's weights. The diffusion model is never updated and gradients never pass through it, so it behaves like a fixed critic suggesting image-space edits. Over 15,000 iterations, renderings from every angle converge toward images the diffusion model considers likely for the prompt.
Two practical tricks made it work. First, prompts are adjusted by camera angle: 'overhead view' for high elevations, and blends of 'front view', 'side view' or 'back view' by azimuth. Without this, the paper shows a dog with multiple faces, because the image model draws a front-facing dog from every direction, a failure later called the Janus problem. Second, classifier-free guidance, which strengthens the prompt's influence, was set to 100, far higher than the single-digit values typical for image generation, because lower values produced oversmoothed results under SDS. The diffusion model was Google's Imagen, using only its 64 by 64 pixel base model. Each scene took around 1.5 hours on a TPUv4 machine with four chips.
On quantitative evaluation, the paper used CLIP R-Precision, the accuracy with which CLIP picks the correct caption for a rendering among distractors. With the CLIP L/14 model, DreamFusion scored 79.7 percent on color renders and 58.5 percent on textureless geometry renders, the latter showing that the shape itself matched the prompt. The authors note that Dream Fields and CLIP-Mesh had an advantage on this metric because they trained with CLIP.
Follow-up work moved fast. NVIDIA's Magic3D, posted in November 2022, added a second stage that refines a textured mesh with a high-resolution latent diffusion model, reporting about 40 minutes per object, twice as fast as DreamFusion, and a 61.7 percent rater preference over it. ProlificDreamer, posted in May 2023, generalized SDS into variational score distillation, treating the 3D scene as a distribution rather than a single point, and reported better quality and diversity at a normal guidance weight of 7.5. Open-source frameworks such as threestudio collected these methods; its documentation notes that DreamFusion guided by DeepFloyd IF performs much better than the Stable Diffusion variant.
The limitations are well documented by the authors. SDS tends to produce oversaturated and oversmoothed results compared with ordinary diffusion sampling, and outputs vary little across random seeds, which the paper attributes to the mode-seeking nature of its reverse KL divergence objective. The 64-pixel guidance model limits fine detail. Recovering 3D from 2D views is ill-posed, since many 3D shapes produce the same images, so the optimization can fall into poor local minima. The method also needs minutes to hours of optimization per object, unlike feed-forward 3D generators that output a model in one pass. In practice, the threestudio implementation lists about 6 GB of GPU memory for training the Stable Diffusion version and about 10 GB for the DeepFloyd IF version, plus about 15 GB to extract text embeddings.
04工作示例
Running score distillation on one prompt with threestudio
Install threestudio on a machine with an NVIDIA GPU of at least 6 GB of memory, following the repository instructions.
Choose the Stable Diffusion DreamFusion configuration and set the prompt to a simple object, for example 'a ripe strawberry'.
Start training and watch the periodic validation renders, which show color, normals and textureless shading from rotating viewpoints.
Note how early renders are blurry blobs and later renders sharpen as SDS updates accumulate.
Rerun with a lower guidance scale and compare: the result should look smoother and less defined, matching the paper's observation.
Export the result as a mesh and inspect it from the back and top to check for duplicated faces or flat geometry.
它显示了什么
The learner ends with a mesh of the prompted object and two runs that show how guidance strength changes SDS output. Checking back and top views reveals whether the Janus problem appeared, and the textureless renders show whether the shape, not just the texture, matches the prompt.
现实世界的实施
The DreamFusion project page offers a searchable gallery of hundreds of text-generated 3D assets, which can be converted to meshes with marching cubes for use in standard 3D software.
NVIDIA's Magic3D (CVPR 2023) applies score distillation in two stages, a coarse hash-grid model then a textured mesh, producing results in about 40 minutes.
ProlificDreamer (NeurIPS 2023) replaces SDS with variational score distillation to reduce oversaturated colors, rendering high-fidelity NeRFs at 512 by 512 pixels.
The open-source threestudio framework reimplements DreamFusion with Stable Diffusion or DeepFloyd IF guidance, so researchers can run SDS on a single GPU with about 6 GB of memory for the Stable Diffusion version.
Researchers use DreamFusion's view-dependent prompting trick, appending 'front view', 'side view' or 'back view' to the text, in later text-to-3D methods to reduce multi-faced objects.
DreamFusion 和分数蒸馏采样的未来
Research after DreamFusion has targeted each of its stated weaknesses. Oversaturation and low diversity led to variational score distillation in ProlificDreamer (2023) and many other modified distillation losses collected in frameworks such as threestudio. Low resolution led to two-stage mesh refinement in Magic3D (2022) and to guidance from higher-resolution latent diffusion models. The multi-face problem prompted multi-view diffusion models that see several views at once, such as MVDream, which threestudio lists among supported methods. Speed is the biggest practical gap: optimization per prompt takes tens of minutes to hours, so the field has also explored generators trained to output 3D directly in a single pass. Whether distillation-based optimization or feed-forward 3D generation becomes the standard approach is not settled in published results, and the DreamFusion authors themselves wrote that higher-resolution synthesis depends on efficiency gains in both diffusion and neural rendering. Evaluation also remains open, since CLIP R-Precision measures prompt agreement but not geometric quality.
付诸实践
为什么这很重要
- 速度与规模. 视觉人工智能可以大规模自动化检查、检测和标记任务。
- 构建选择. 创意团队可以通过更少的手动修改更快地构建概念原型。
- 团队与工作流程. 操作可以使用以前难以处理的图像和视频信号。
留意
- 如果出处不明,肖像权和同意可能会成为法律风险。
- 模型性能可能因光照、人口统计和环境的不同而有所不同。
- 除非监控置信阈值,否则误报可能会被忽视。
后续步骤
- 定义精确度、召回率和错误成本的接受标准。
- 使用符合实际生产条件的数据进行测试。
- 为低置信度或高影响力的预测添加人工审核。
- 跟踪模型漂移并在相机或数据集更改后重新验证。
资料来源与延伸阅读
- arXiv (ICLR 2023)DreamFusion: Text-to-3D using 2D Diffusion
- Google ResearchDreamFusion project page
- Google ResearchGoogle at ICLR 2023
- arXiv (CVPR 2023)Magic3D: High-Resolution Text-to-3D Content Creation
- arXiv (NeurIPS 2023)ProlificDreamer: High-Fidelity and Diverse Text-to-3D Generation with Variational Score Distillation
- GitHubthreestudio-project/threestudio
不断探索
常见问题
什么是 DreamFusion 和分数蒸馏采样?
DreamFusion is a 2022 Google Research method that creates a 3D object from a text prompt without any 3D training data. Its key idea, Score Distillation Sampling (SDS), uses a frozen 2D text-to-image diffusion model as a critic that grades rendered views of a 3D scene and pushes the scene toward what the prompt describes. SDS became the foundation of most optimization-based text-to-3D research.
DreamFusion 优化了哪些 3D 表示?
DreamFusion 优化了 NeRF,使其渲染视图满足 2D 扩散模型对文本提示的判断。
DreamFusion 需要多少 3D 训练数据?
DreamFusion 使用冻结的 2D 文本到图像扩散模型作为唯一的监督,不需要 3D 训练数据。
Score Distillation Sampling 中的计算捷径是什么?
SDS 从扩散噪声预测和采样噪声形成梯度,通过扩散模型停止梯度以避免其完全雅可比行列式。
为什么 DreamFusion 在其实验中使用了高无分类器引导?
该论文报告说,高指导提高了 SDS 输出的视觉质量,否则其模式搜索目标可能会产生过度平滑的结果;几何形状无法保证。
最初的 DreamFusion 使用哪个 2D 模型作为其冻结先验?
DreamFusion 建立在 Google 的 Imagen 文本到图像扩散模型上,作为冻结评分函数。