Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
CGと機械学習
Search
Kaito
May 04, 2021
Programming
0
170
CGと機械学習
CGと機械学習の入門
Kaito
May 04, 2021
Tweet
Share
More Decks by Kaito
See All by Kaito
ASGIについて
kaitolucifer
0
290
Other Decks in Programming
See All in Programming
AIと私たちの学習の変化を考える - Claude Codeの学習モードを例に
azukiazusa1
10
4k
もうちょっといいRubyプロファイラを作りたい (2025)
osyoyu
1
430
AIでLINEスタンプを作ってみた
eycjur
1
230
速いWebフレームワークを作る
yusukebe
5
1.7k
実用的なGOCACHEPROG実装をするために / golang.tokyo #40
mazrean
1
270
アルテニア コンサル/ITエンジニア向け 採用ピッチ資料
altenir
0
100
複雑なドメインに挑む.pdf
yukisakai1225
5
1.1k
1から理解するWeb Push
dora1998
7
1.9k
Vue・React マルチプロダクト開発を支える Vite
andpad
0
110
The Past, Present, and Future of Enterprise Java with ASF in the Middle
ivargrimstad
0
100
Design Foundational Data Engineering Observability
sucitw
3
190
プロパティベーステストによるUIテスト: LLMによるプロパティ定義生成でエッジケースを捉える
tetta_pdnt
0
320
Featured
See All Featured
Learning to Love Humans: Emotional Interface Design
aarron
273
40k
Build The Right Thing And Hit Your Dates
maggiecrowley
37
2.9k
Building Better People: How to give real-time feedback that sticks.
wjessup
368
19k
Done Done
chrislema
185
16k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
61k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
507
140k
How STYLIGHT went responsive
nonsquared
100
5.8k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
229
22k
Producing Creativity
orderedlist
PRO
347
40k
Why You Should Never Use an ORM
jnunemaker
PRO
59
9.5k
Why Our Code Smells
bkeepers
PRO
339
57k
Code Review Best Practice
trishagee
70
19k
Transcript
CGと機械学習(⼊⾨)
⽬次 2 Ø CGレンダリングの紹介 Ø ラスタライゼーション (Rasterization) Ø レイトレーシング (Ray
Tracing) Ø Deep Denoising Ø Deep Denoising (Nvidia) Ø Denoising (Pixar/Disney) Ø DeepShading Ø Super Sampling Ø MSAA Ø チェックボード (Sony) Ø DLSS (Nvidia) Ø Differentiable Rendering
CGレンダリングの紹介 3
ラスタライゼーション (Rasterization) 4
Rasterization 5 Rasterization
Graphics Pipeline 6 Rasterization
Graphics Pipeline 7 Rasterization
Graphics Pipeline 8 Rasterization
Graphics Pipeline 9 Rasterization
Graphics Pipeline 10 Rasterization
Graphics Pipeline 11 Rasterization
12 Rasterization Graphics Pipeline
13 Rasterization Blinn-Phong Reflectance Model Ø 局所的な反射モデル Ø 反射を3種類に分ける Ø
「鏡⾯反射」(specular reflection) Ø 「拡散反射」(diffuse reflection) Ø 「環境反射」(ambient reflection)
14 Rasterization Diffuse Reflection Ø ランバート反射を使⽤ Ø カメラの位置と関係ない
15 Rasterization Diffuse Reflection
16 Rasterization Specular Reflection Ø カメラの位置と関係ある Ø ⼊射⾓=反射⾓ Ø 反射光の⽅向とカメラの⽅向が近ければ近いほど明るい
17 Rasterization Specular Reflection Ø viewベクトル(カメラ⽅向)と⼊射光ベクトルのハーフベクトルを計算 Ø ハーフベクトルとshading pointの法線ベクトルのドット積を計算
18 Rasterization Specular Reflection
19 Rasterization Ambient Reflection Ø カメラや光源に依存しないコンスタントな発光 Ø shading pointが真っ暗になるのを防ぐ
20 Rasterization Blinn-Phong Reflectance Model
21 Rasterization Shading Type
レイトレーシング (Ray Tracing) 22
Why Ray Tracing? 23 レイトレーシング (Ray Tracing) Ø ラスタライゼーションは速いが、品質が悪い Ø
グローバルイルミネーションの処理が難しい Ø 影などは別途処理必要(shadow mapping) Ø 光沢反射の実現が難しい
Emission Theory of Vision? 24 レイトレーシング (Ray Tracing)
Recursive (Whitted-Style) Ray Tracing 25 レイトレーシング (Ray Tracing) J. Turner
Whitted - Wikipedia
26 レイトレーシング (Ray Tracing) Recursive (Whitted-Style) Ray Tracing Spheres and
Checkerboard, T. Whitted, 1979
Radiometry 27 レイトレーシング (Ray Tracing) Ø Whitted-Style Ray Tracing Ø
結局はBlinn-Phong modelを使っている Ø 正しくない Ø Radiometry (放射測定)が必要 Ø Path Tracingの基礎となる
Radiometry 28 レイトレーシング (Ray Tracing) Radiant Energyとして定義する Radiant Flux (power)
として定義する 単位時間内に放出、吸収、反射または伝播したpower
Radiometry 29 レイトレーシング (Ray Tracing)
Radiometry (Radiant Intensity) 30 レイトレーシング (Ray Tracing) 定義︓Unit Solid Angle
(単位⽴体⾓) 毎に放出したpower
Radiometry (Radiant Intensity) 31 レイトレーシング (Ray Tracing) Ø ⾓度 (angle)
Ø 𝜃 = ! " Ø 円のラジアン (radian) は2𝜋 Ø ⽴体⾓ (solid angle) Ø Ω = # "! Ø 球のステラジアン (steradian) は4𝜋
Radiometry (Irradiance) 32 レイトレーシング (Ray Tracing) 定義︓単位投影エリア (unit project area)
毎に吸収したpower
Radiometry (Irradiance) 33 レイトレーシング (Ray Tracing)
Radiometry (Radiance) 34 レイトレーシング (Ray Tracing) 定義︓単位投影エリア、且つ単位⽴体⾓毎に放出、吸収、反射または伝播したpower
Radiometry (Radiance) 35 レイトレーシング (Ray Tracing)
BRDF 36 レイトレーシング (Ray Tracing) Ø Bidirectional Reflectance Distribution Function
Ø ⼊射光を特定の⽅向にどれぐらい反射するのかを定義する⽅程式(Material Model)
Reflection Equation 37 レイトレーシング (Ray Tracing) Ø Refletion Equation
Rendering Equation 38 レイトレーシング (Ray Tracing) Ø Refletion Equation Ø
Rendering Equation Ø ⾃発光の物体もカバーできるよう発光項𝐿$ を追加
Monte Carlo積分 39 レイトレーシング (Ray Tracing)
Monte Carlo積分 40 レイトレーシング (Ray Tracing)
Monte Carlo積分 41 レイトレーシング (Ray Tracing)
Ray Tracing (Path Tracing) 42 レイトレーシング (Ray Tracing)
Ray Tracing (Path Tracing) 43 レイトレーシング (Ray Tracing) Ø 直接照明のみ考える場合
Ray Tracing (Global Illumination) 44 レイトレーシング (Ray Tracing) Ø 間接照明の場合は︖
Ø ⼤域照明 (Global Illumination) Ø P点をカメラと仮定してQ点の直接照明を計算するのと同じ
Ray Tracing (Path Tracing) 45 レイトレーシング (Ray Tracing)
Ray Tracing (Path Tracing) 46 レイトレーシング (Ray Tracing) Ø 問題点1
– 指数爆発 Ø 𝑏𝑜𝑢𝑛𝑐𝑒𝑠 = 1の場合のみ指数爆発が起こらない
Ray Tracing (Path Tracing) 47 レイトレーシング (Ray Tracing) Ø Path
Tracing Ø 𝑁 ≠ 1の場合はDistributed Ray Tracingと呼ぶ
Ray Tracing (Path Tracing) 48 レイトレーシング (Ray Tracing) Ø 𝑁
= 1の場合はノイズが⼤きすぎる Ø ピクセル毎に複数本の光線を⾶ばす
Ray Tracing (Path Tracing) 49 レイトレーシング (Ray Tracing)
Ray Tracing (Path Tracing) 50 レイトレーシング (Ray Tracing) Ø 問題点2
– 再帰の停⽌条件に⼊る確率が⼩さすぎる
Ray Tracing (Path Tracing) 51 レイトレーシング (Ray Tracing) 3回跳ね返る
Ray Tracing (Path Tracing) 52 レイトレーシング (Ray Tracing) 17回跳ね返る
Ray Tracing (Path Tracing) 53 レイトレーシング (Ray Tracing)
Ray Tracing (Path Tracing) 54 レイトレーシング (Ray Tracing)
Ray Tracing (Path Tracing) 55 レイトレーシング (Ray Tracing)
Ray Tracing (Path Tracing) 56 レイトレーシング (Ray Tracing)
Ray Tracing (Path Tracing) 57 レイトレーシング (Ray Tracing)
Ray Tracing (Path Tracing) 58 レイトレーシング (Ray Tracing) 完成︕︕︕
Ray Tracing (Path Tracing) 59 レイトレーシング (Ray Tracing) The Cornell
box — http://www.graphics.cornell.edu/online/box/compare.html 写真 Path Tracing Global Illumination
Deep Denoising 60
Deep Denoising 61 Deep Denoising 1 sample per pixel rendering
Deep Denoising (Nvidia) 62 Deep Denoising Interactive Reconstruction of Monte
Carlo Image Sequences using a Recurrent Denoising Autoencoder
Deep Denoising (Depth) 63 Deep Denoising
Deep Denoising (Surface normal) 64 Deep Denoising
Deep Denoising (Nvidia) 65 Deep Denoising Interactive Reconstruction of Monte
Carlo Image Sequences using a Recurrent Denoising Autoencoder
Deep Denoising (Pixar/Disney) 66 Deep Denoising Kernel-Predicting Convolutional Networks for
Denoising Monte Carlo Renderings
Deep Denoising (Pixar/Disney) 67 Deep Denoising Kernel-Predicting Convolutional Networks for
Denoising Monte Carlo Renderings
Deep Denoising (Pixar/Disney) 68 Deep Denoising
Deep Shading 69 Deep Denoising Deep Shading: Convolutional Neural Networks
for Screen Space Shading
スーパーサンプリング 70
MSAA 71 スーパーサンプリング
MSAA 72 スーパーサンプリング ピクセル毎にN×Nサンプルを取る
MSAA 73 スーパーサンプリング ピクセル内で平均する
MSAA 74 スーパーサンプリング
MSAA 75 スーパーサンプリング 4×4 Super Sampling (MSAA 4X)
チェックボード 76 スーパーサンプリング Ø Sonyが採⽤した技術 Ø 各フレームは交替に半分のピクセルずつをレンダリングする Ø 残りの半分はbilinearまたはBicubic補完 Ø
画⾯上に出⼒するフレームは現在フレームと1コマ前のものの融合 Ø 問題点 Ø 髪の⽑など信号の変化が激しい部位はバレる Ø 運動する時は残影を残してしまう
DLSS 1.0 77 スーパーサンプリング Ø Nvidiaが考案した技術 Ø 深層学習スーパーサンプリング (Deep Learning
Super Sampling) Ø スーパーサンプリングによるアンチエイリアシング Ø 問題点 Ø 運動すると違和感を感じることがある(残影や点滅) 訓練済みモデル 特化したモデル 64枚以上8K画像 1080P画像 超解像度 8K画像 スーパーサンプリング 4K画像
DLSS 2.0 78 スーパーサンプリング Ø Nvidiaが考案した技術 Ø 完全に作り直し Ø 時間軸の導⼊
Ø 問題点 Ø 反射は補完されない (低解像度のまま) 出典︓NVIDIA DLSS 2.0: AI レンダリングの⼤きな⾶躍
DLSS 2.0 79 スーパーサンプリング
DLSS 2.0 80 スーパーサンプリング Native 4K DLSS 2.0 (quality) CyberPunk
2077 キアヌ・リーブズ
Differentiable Rendering 81
Differentiable Rendering 82 Differentiable Rendering Ø レンダリングの中の微分不可能の処理を微分可能な処理に置き換える Ø 3Dシーンを理解する (Inverse
Rendering)
Differentiable Rendering 83 Differentiable Rendering … … カメラの位置最適化 facebookresearch/pytorch3d: PyTorch3D
is FAIR's library of reusable components for deep learning with 3D data
Differentiable Rendering 84 Differentiable Rendering 6dof回転を予測 tensorflow/graphics: TensorFlow Graphics: Differentiable
Graphics Layers for TensorFlow
Differentiable Rendering 85 Differentiable Rendering Meshセグメンテーション tensorflow/graphics: TensorFlow Graphics: Differentiable
Graphics Layers for TensorFlow