tensorflow graphics详解
詳細(xì)英文文檔地址:
? ? ? 地址1:https://github.com/tensorflow/graphics
? ? ? 地址2:https://tensorflow.google.cn/graphics(自動(dòng)跳轉(zhuǎn)到 地址1)
????? 說明:因?yàn)閠ensorflow地址大部分無法訪問,可以在https://github.com/tensorflow/下找到需要的內(nèi)容
TensorFlow重磅推出一個(gè)全新的圖形工具TensorFlow Graphics,結(jié)合計(jì)算機(jī)圖形學(xué)和計(jì)算機(jī)視覺技術(shù),以無監(jiān)督的方式解決復(fù)雜3D視覺任務(wù)。
近年來,可插入到神經(jīng)網(wǎng)絡(luò)架構(gòu)中的一種新型可微圖形層(differentiable graphics layers)開始興起。
從空間變換器(spatial transformers)到可微圖形渲染器,這些新型的神經(jīng)網(wǎng)絡(luò)層利用計(jì)算機(jī)視覺、圖形學(xué)研究獲得的知識(shí)來構(gòu)建新的、更高效的網(wǎng)絡(luò)架構(gòu)。它們將幾何先驗(yàn)和約束顯式地建模到神經(jīng)網(wǎng)絡(luò)中,為能夠以自監(jiān)督的方式進(jìn)行穩(wěn)健、高效訓(xùn)練的神經(jīng)網(wǎng)絡(luò)架構(gòu)打開了大門。
1.概述(Overview)
從高級(jí)層面來說,計(jì)算機(jī)圖形學(xué)的pipeline需要3D物體及其在場(chǎng)景中的絕對(duì)位置、構(gòu)成它們的材質(zhì)的描述、光、以及攝像頭。然后,渲染器對(duì)這個(gè)場(chǎng)景描述進(jìn)行解釋,生成一個(gè)合成渲染。
相比之下,計(jì)算機(jī)視覺系統(tǒng)是從圖像開始的,并試圖推斷出場(chǎng)景的相關(guān)參數(shù)。也就是說,計(jì)算機(jī)視覺系統(tǒng)可以預(yù)測(cè)場(chǎng)景中有哪些物體,它們由什么材料構(gòu)成,以及它們的3D位置和方向。
?
訓(xùn)練一個(gè)能夠解決這些復(fù)雜的3D視覺任務(wù)的機(jī)器學(xué)習(xí)系統(tǒng)通常需要大量的數(shù)據(jù)。由于給數(shù)據(jù)打標(biāo)簽是一個(gè)成本高昂而且復(fù)雜的過程,因此設(shè)計(jì)能夠理解三維世界、而且無需太多監(jiān)督的機(jī)器學(xué)習(xí)模型的機(jī)制非常重要。
將計(jì)算機(jī)視覺和計(jì)算機(jī)圖形學(xué)技術(shù)結(jié)合起來,我們得以利用大量現(xiàn)成的無標(biāo)記數(shù)據(jù)。
如下圖所示,這個(gè)過程可以通過合成分析來實(shí)現(xiàn),其中視覺系統(tǒng)提取場(chǎng)景參數(shù),圖形系統(tǒng)根據(jù)這些參數(shù)返回圖像。如果渲染結(jié)果與原始圖像匹配,則說明視覺系統(tǒng)已經(jīng)準(zhǔn)確地提取出場(chǎng)景參數(shù)了。
在這種設(shè)置中,計(jì)算機(jī)視覺和計(jì)算機(jī)圖形學(xué)相輔相成,形成了一個(gè)類似于自動(dòng)編碼器的機(jī)器學(xué)習(xí)系統(tǒng),能夠以一種自監(jiān)督的方式進(jìn)行訓(xùn)練。
2.安裝 TensorFlow Graphics?
地址:https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/g3doc/install.md
?CPU 版:pip install --upgrade tensorflow-graphics
?GPU 版:pip install --upgrade tensorflow-graphics-gpu
3.API Documentation
地址:https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/g3doc/api_docs/python/tfg.md
4.兼容性(Compatibility)
TensorFlow Graphics完全兼容最新發(fā)布的穩(wěn)定版本TensorFlow,tf-nightly和tf-nightly-2.0-preview。 所有功能都與graph and eager execution.兼容。
5.調(diào)試(Debugging)
Tensorflow Graphics 嚴(yán)重依賴 L2 normalized tensors,以及處于預(yù)定范圍內(nèi)的特定功能的輸入,檢查所有這些都需要在循環(huán)中,因此默認(rèn)情況下不會(huì)激活。建議在特定的訓(xùn)練周期內(nèi)打開這些檢查,以確保一切都按預(yù)期運(yùn)行。
地址:https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/g3doc/debug_mode.md(該文檔提供了啟用該功能的說明)
6.Colab 教程
為了幫助您開始使用TF Graphics提供的一些功能,下面提供了一些Colab筆記本,并且大致按順序排序。涉及大范圍的主題,包括物體姿態(tài)估計(jì)(object pose estimation),插值interpolation,物體材料object materials,照明lighting,非剛性表面變形non-rigid surface deformation,球面諧波?spherical harmonics和網(wǎng)格卷積mesh convolutions。
6.1.入門級(jí)(Beginner)
?物體姿態(tài)估計(jì)(?Object pose estimation?)
???? 備用地址:https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/notebooks/6dof_alignment.ipynb
Camera intrisic optimization
??? 備用地址:https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/notebooks/intrinsics_optimization.ipynb
6.2.中等難度(Intermediate)
?B樣條和球面線性插值(? B-spline and slerp interpolation)
? 備用地址:https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/notebooks/interpolation.ipynb
反射率(Reflectanc)
備用地址:https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/notebooks/reflectance.ipynb
?非剛性表面變形(Non-rigid surface deformation)
? 備用地址:https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/notebooks/non_rigid_deformation.ipynb
6.3.高等難度(Advanced)
球面諧波渲染(Spherical harmonics rendering)
備用地址:https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/notebooks/spherical_harmonics_approximation.ipynb
環(huán)境地圖優(yōu)化(Environment map optimization)
備用地址:https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/notebooks/spherical_harmonics_optimization.ipynb
語義網(wǎng)格分割(Semantic mesh segmentation)
備用地址:https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/notebooks/mesh_segmentation_demo.ipynb
7.TensorBoard 3D
可視化debug是評(píng)估實(shí)驗(yàn)是否朝著正確方向進(jìn)行的一種很好的方法。為此,TensorFlow Graphics提供了一個(gè)TensorBoard插件,可以交互式地對(duì)3D網(wǎng)格和點(diǎn)云進(jìn)行可視化。
地址1:https://colab.research.google.com/github/tensorflow/tensorboard/blob/master/tensorboard/plugins/
???????????? mesh/Mesh_Plugin_Tensorboard.ipynb(插件使用方法)——無法訪問
地址1-1.https://github.com/tensorflow/tensorboard/tree/master/tensorboard/plugins/mesh(內(nèi)容與地址二相同)
說明:因?yàn)榈刂?無法訪問,可以在https://github.com/tensorflow/下找到需要的內(nèi)容
地址2:https://github.com/tensorflow/graphics/blob/master/tensorflow_graphics/g3doc/tensorboard.md(安裝和配置)
注意:TensorBoard 3D目前與急切執(zhí)行和TensorFlow 2不兼容。
8.后續(xù)更新(Coming next...)
在許多方面,我們希望發(fā)布重新采樣器,額外的3D卷積和池操作符,以及可區(qū)分的光柵化器!
在Twitter上關(guān)注我們,了解最新消息!
地址:https://twitter.com/_TFGraphics_? (無法訪問)
9.附加信息(Additional Information)
您可以在Apache 2.0許可下使用此軟件。
10.社區(qū)(Community)
作為TensorFlow的一部分,我們致力于營(yíng)造一個(gè)開放和熱情的環(huán)境。
???? Stack Overflow:詢問或回答技術(shù)問題。地址:https://stackoverflow.com/questions/tagged/tensorflow
???? GitHub:報(bào)告錯(cuò)誤或發(fā)出功能請(qǐng)求。????? 地址:https://github.com/tensorflow/graphics/issues
???? TensorFlow博客:及時(shí)了解TensorFlow團(tuán)隊(duì)的內(nèi)容和社區(qū)的最佳文章。地址:https://medium.com/tensorflow
???? Youtube頻道:關(guān)注TensorFlow節(jié)目。??? 地址:http://youtube.com/tensorflow/
?
。
?
?
?
??
總結(jié)
以上是生活随笔為你收集整理的tensorflow graphics详解的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 物流基础知识(十五)
- 下一篇: [填坑]ubuntu 18.04+Win