当前位置:网站首页>浅析 Ref-NeRF
浅析 Ref-NeRF
2022-07-03 20:32:00 【张春成】
浅析 Ref-NeRF
NeRF 是目前比较流行的三维渲染网络,本文以新的 RefNeRF 为契机, 尝试说明三维表面中的法线与渲染之间的紧密联系。
研究背景
渲染方法
我们把渲染过程简化为:拍摄一个物体时,求物体的照片上某一个点的颜色

传统的方法需要首先获得物体的三维模型,并搭建三维场景,之后通过计算获得每个区域的颜色值。
我们既可以通过建立面片模型来渲染,也可以通过体积分的方法来渲染。


这里我们考虑两个基本的东西,一个是物体,另一个是观察者,
物体的模型是物理的,它不随观察的视角而改变; 观察者以各种角度对物体模型进行观测,它可以简化为一个角度。
而 NeRF 方法就是抓住了这两个关键点,将三维物体的渲染过程抽象为一个函数,区别于传统方法的地方是,它不再依赖于显式地对三维物体进行建模。
Neural Radiance Fields & Multi-layer perception Neural Radiance Fields (NeRF) is a popular view synthesis technique that represents a scene as a continuous volumetric function, parameterized by multi-layer perception (MLP) that provide the volume density and view dependent emitted radiance at each location.
从神经网络的角度来说,渲染过程如下式所示
其中,代表模型参数,代表渲染的位置,代表观察角度。 网络训练过程是以多个视角拍摄同一物体,从而优化参数,
因此,可以认为物体的表面信息被编码在网络参数中。而新角度的渲染可以通过这组参数计算得到。
NeRF的问题
They often fail to accurately capture and reproduce the appearance of glossy surfaces

即 NeRF 处理不好光滑表面。究其原因,是因为 NeRF 对于表面纹理的处理是依靠插值

为什么这么说?因为原函数是连续函数
因此,没有特殊机制的情况下,当渐变时,输出必然也是渐变的。宏观上就会呈现出“插值”的效果。体现在渲染结果上,就是纹理的颜色没有明确的边界,看上去非常模糊。
新方法
主要思想
新方法学习物体表面的三维结构,在渲染颜色时不再依赖于插值算法

这里所说的三维结构的核心是局部法线的方向。
法线有多重要?
举一个例子说明这个问题,如果用传统的方法渲染一个物体,除了需要它的三维表面结构和纹理贴图颜色之外,还需要它的表面法线

如果改变它的法线方向,就会得到完全不同的渲染效果

产生这个现象的原因能过通过下图解释,在考虑环境光照的条件下,物体某个点的颜色可以简化成由两个因素构成
其中,代表材质的扩散(diffuse)颜色,这个颜色取决于物体本身的性质,代表环境光照带来的颜色。

由于环境光是经过物体反射的,因此它不可避免地受到光照角度和表面法线的共同作用。
Ref-NeRF算法就是在学习模型参数的过程中,通过增加约束的方式同时学习这些法线和入射光的耦合结构。
网络结构

在原始 NeRF 方法中,
输入 代表位置; 输入 代表观察角度; 输出 代表材质密度; 输出 代表颜色值; 中间变量 代表瓶颈向量,有点像 ResNet 的跳层传输。
而 Ref-NeRF 方法增加的中间变量有,
:被光照产生的颜色和本身的颜色; :光照颜色的加权; :局部表面粗糙度; :局部法线。
为什么除了法线之外还引入了这么多东西?其实很好理解。
:控制外来光线与本身颜色的数值和比例; :就是考虑了表面法线之后,局部颜色值“极大”地受到法线的影响,但实际中,由于物体表面并不绝对光滑,这导致实际结果与理论结果差异较大。在这个网络中,表面越粗糙,那么做的平滑就越强,平滑是通过拟合 vMF 分布实现的。
We introduce a technique,which we call an Integrated Directional Encoding (IDE), that enables the directional MLP to efficiently represent the function of outgoing radiance for materials with any continuously-valued roughness

结果
与NeRF方法的比较


可见,Ref 方法能够比较准确地估计出球面和圆柱结构的表面法线结构,以及哪些信息是由环境光线所引起的。这就赋予了这个模型认识并学习“镜面反射”的能力。
场景编辑
最后,由于该模型既学习到了物体的表面信息,又学习到了环境光线的信息,因此可以通过改变这两个因素,来对三维物体和场景进行“编辑”。

We can edit the diffuse color of the car without affecting the specular reflections of its glossy paint

We can plausibly modify the roughness of the car and material balls by manipulating the κ values used in the IDE
边栏推荐
- Measurement fitting based on Halcon learning -- Practice [1]
- MySQL master-slave synchronization principle
- Global and Chinese markets of active matrix LCD 2022-2028: Research Report on technology, participants, trends, market size and share
- It is discussed that the success of Vit lies not in attention. Shiftvit uses the precision of swing transformer to outperform the speed of RESNET
- Micro service knowledge sorting - three pieces of micro Service Technology
- Oak-d raspberry pie cloud project [with detailed code]
- Test access criteria
- Basic number theory -- Chinese remainder theorem
- JMeter plug-in installation
- Global and Chinese markets for medical temperature sensors 2022-2028: Research Report on technology, participants, trends, market size and share
猜你喜欢

2022 safety officer-c certificate examination and safety officer-c certificate registration examination

Popularize the basics of IP routing
![Measurement fitting based on Halcon learning -- Practice [1]](/img/71/9f6c27aa89035b2550bdb0ac902045.jpg)
Measurement fitting based on Halcon learning -- Practice [1]

Derivation of decision tree theory

Explore the internal mechanism of modern browsers (I) (original translation)

Qt6 QML Book/Qt Quick 3D/基础知识

2.6 formula calculation

Sparse matrix (triple) creation, transpose, traversal, addition, subtraction, multiplication. C implementation

Machine learning support vector machine SVM

Research Report on the overall scale, major manufacturers, major regions, products and application segmentation of rotary tablet presses in the global market in 2022
随机推荐
MySQL learning notes - single table query
AI enhanced safety monitoring project [with detailed code]
浅议.NET遗留应用改造
Instructions for common methods of regular expressions
2.7 format output of values
2.2 integer
Golang type assertion and conversion (and strconv package)
Discussion Net legacy application transformation
Popularize the basics of IP routing
Basic command of IP address configuration ---ip V4
Virtual machine installation deepin system
How to handle wechat circle of friends marketing activities and share production and release skills
《ActBERT》百度&悉尼科技大学提出ActBERT,学习全局局部视频文本表示,在五个视频-文本任务中有效!...
Exercises of function recursion
Sword finger offer 30 Stack containing min function
Use of CMD command
[postgresql]postgresql custom function returns an instance of table type
Battle drag method 1: moderately optimistic, build self-confidence (1)
2.6 formula calculation
About unregistered transfer login page