深度学习(三十五)——Style Transfer(2), YOLOv3, Tiny-YOLO, One-stage vs. Two-stage
Style Transfer
Texture Networks: Feed-forward Synthesis of Textures and Stylized Images
這篇論文屬于fast style transfer類的改進。它是Skolkovo Institute of Science and Technology & Yandex的Dmitry Ulyanov的作品。
Dmitry Ulyanov的個人主頁:
https://dmitryulyanov.github.io
Skolkovo位于莫斯科郊外,相當于俄國的硅谷。
代碼:
https://github.com/DmitryUlyanov/texture_nets
上圖是該論文提出的網絡結構,其中包括了兩個部分:
1.descriptor network(以下簡稱D網絡)。這部分的使用方法和Gatys方法基本一致:風格圖片過一下預訓練好的Alex-Net來生成紋理特征P。
2.論文的主要創新點在于generator network(以下簡稱G網絡)。
1)假設有一批圖片A,通過G網絡得到了風格圖片G(A)。
2)G(a)和a做比較得到content loss,G(A)和P做比較得到style loss。
3)迭代優化上述兩個loss,得到訓練好的G網絡。
4)Inference時,直接將圖片a輸入G網絡,就得到了風格變換后的圖片G(a)。
Perceptual Losses for Real-Time Style Transfer and Super-Resolution
這篇論文是李飛飛組的Justin Johnson的作品。
Justin Johnson的個人主頁:
https://cs.stanford.edu/people/jcjohns/
代碼:
https://github.com/OlavHN/fast-neural-style
https://github.com/lengstrom/fast-style-transfer/
可以看出該論文的方法和Texture Networks基本一致,差別僅在于generator network和descriptor network的結構,略有不同而已。這里不再贅述。
參考:
https://blog.csdn.net/Hungryof/article/details/61195783
超越fast style transfer----任意風格圖和內容圖0.1秒出結果
https://zhuanlan.zhihu.com/p/35798776
快速風格遷移(fast-style-transfer)
其他
原版的neural style是用Gram矩陣來進行匹配風格,但是也有用其他的。例如:
MRF loss(ombining markov random fields and convolutional neural networks for image synthesis.)
Adversarial loss(C. Li and M. Wand. Precomputed real-time texture synthesis with markovian generative adversarial networks. In ECCV,2016)
梯度直方圖(P. Wilmot, E. Risser, and C. Barnes. Stable and controllable neural texture synthesis and style transfer using histogram losses. arXiv preprint arXiv:1701.08893 , 2017)
參考
https://zhuanlan.zhihu.com/p/26746283
圖像風格遷移(Neural Style)簡史
https://mp.weixin.qq.com/s/64H2dDcaTcKdKaOnwdsoEg
基于深度學習的藝術風格化研究
https://blog.csdn.net/red_stone1/article/details/79055467
人臉識別與神經風格遷移
https://blog.csdn.net/cicibabe/article/details/70885715
卷積神經網絡圖像風格轉移
https://blog.csdn.net/stdcoutzyx/article/details/53771471
圖像風格轉換(Image style transfer)
https://blog.csdn.net/u011534057/article/details/78935202
風格遷移學習筆記(1):Multimodal Transfer: A Hierarchical Deep Convolutional Neural Network for Fast
https://blog.csdn.net/u011534057/article/details/78935230
風格遷移學習筆記(2):Universal Style Transfer via Feature Transforms
https://mp.weixin.qq.com/s/l3hQCQWh5NgihzTs2A049w
風格遷移原理及tensorflow實現
https://mp.weixin.qq.com/s/5Omfj-fYRDt9j2VZH1XXkQ
如何用Keras打造出“風格遷移”的AI藝術作品
https://mp.weixin.qq.com/s/4q-9QsXD04mD-f2ke7ql8A
tensorflow風格遷移網絡訓練與使用
https://blog.csdn.net/hungryof/article/details/53981959
談談圖像的Style Transfer(一)
https://blog.csdn.net/Hungryof/article/details/71512406
談談圖像的style transfer(二)
https://mp.weixin.qq.com/s/8Fz6Q-6VgJsAko0K7HDsow
一個模型搞定所有風格轉換,直接在瀏覽器實現(demo+代碼)
https://github.com/cysmith/neural-style-tf
TensorFlow (Python API) implementation of Neural Style.這個項目實現了兩張圖片的畫風融合,非常牛。
https://github.com/jinfagang/pytorch_style_transfer
這個和上面的一樣,不過是用pytorch實現的。
https://mp.weixin.qq.com/s/g1hpuzH36j_rbYR23Mwx0w
開源圖像風格遷移,快看看大畫家的潛力股
YOLOv3
2018年4月,pjreddie提出了YOLOv3。
論文:
《YOLOv3: An Incremental Improvement》
代碼:
https://github.com/YunYang1994/tensorflow-yolov3
TF版本
它的改進點在于:
1.骨干網絡再次升級。
上圖是YOLOv3的網絡結構圖。由于這個網絡共有53層Conv,因此也被作者稱作Darknet-53。
從結構來看,它明顯借鑒了ResNet的殘差結構。而3x3、1x1卷積核的使用,則顯然是SqueezeNet的思路。
2.多尺度先驗框。
YOLOv2從兩個不同尺度的conv層輸出中提取bbox,而YOLOv3從3個不同尺度的conv層輸出中提取bbox。多尺度特征提取在U-NET、DenseNet中,早就廣泛使用了,用到這里也很自然。
上圖是YOLOv3網絡輸出的tensor的格式。
3.對象分類softmax改成logistic。
預測對象類別時不使用softmax,改成使用logistic的輸出進行預測。這樣能夠支持多標簽對象(比如一個人有Woman 和 Person兩個標簽)。
實際上,就是把loss由tf.nn.softmax_cross_entropy_with_logits換成tf.nn.sigmoid_cross_entropy_with_logits。它的特點是每個類別給出一個二分類(是/否)的置信度,如果某個對象是多標簽的話,則它可能有多個類別的置信度接近1。
參考:
https://zhuanlan.zhihu.com/p/34945787
YOLOv3:An Incremental Improvement全文翻譯
https://mp.weixin.qq.com/s/UWuCiV6dBk9Z0XusEBS6-g
物體檢測經典模型YOLO新升級,就看一眼,速度提升3倍!
https://mp.weixin.qq.com/s/BF7mj-_D303cLiD5e6oy6w
期待已久的—YOLO V3
https://mp.weixin.qq.com/s/-Ixqxx6QGJDTM4g50y6LyA
進擊的YOLOv3,目標檢測網絡的巔峰之作
https://zhuanlan.zhihu.com/p/46691043
YOLO v1深入理解
https://zhuanlan.zhihu.com/p/47575929
YOLOv2 / YOLO9000深入理解
https://zhuanlan.zhihu.com/p/49556105
YOLO v3深入理解
https://mp.weixin.qq.com/s/0lyDv9b-mpvSFYXqyngT-w
實用教程!使用YOLOv3訓練自己數據的目標檢測
https://mp.weixin.qq.com/s/PkFtZ0Iqf7PBGyE5a_IJ4Q
YOLO v3的TensorFlow實現,GitHub完整源碼解析
https://mp.weixin.qq.com/s/Vuuca3A7luCyCQ-jBKMIcw
YOLO v3目標檢測的PyTorch實現,GitHub完整源碼解析!
https://mp.weixin.qq.com/s/2aeBBjCbWdweYmNrTaWqqw
一文看盡目標檢測:從YOLO v1到v3的進化之路
Tiny-YOLO
YOLO系列還包括了一個速度更快但精度稍低的嵌入式版本系列——Tiny-YOLO。
到了YOLOv3時代,Tiny-YOLO被改名為YOLO-LITE。
此外,還有使用其他輕量級骨干網絡的YOLO變種,如MobileNet-YOLOv3。
參考:
https://mp.weixin.qq.com/s/xNaXPwI1mQsJ2Y7TT07u3g
YOLO-LITE:專門面向CPU的實時目標檢測
https://zhuanlan.zhihu.com/p/50170492
重磅!YOLO-LITE來了
https://zhuanlan.zhihu.com/p/52928205
重磅!MobileNet-YOLOv3來了
One-stage vs. Two-stage
雖然我們在概述一節已經提到了One-stage和Two-stage的概念。但鑒于這個概念的重要性,在介紹完主要的目標檢測網絡之后,很有必要再次總結一下。
上兩圖是One-stage和Two-stage的網絡結構圖。
One-stage一步搞定分類和bbox問題。
而Two-stage則分為兩步:
1.根據區域是foreground,還是background,生成bbox。
2.對bbox進行分類和細調。
論文:
《Speed/accuracy trade-offs for modern convolutional object detectors》
總結
以上是生活随笔為你收集整理的深度学习(三十五)——Style Transfer(2), YOLOv3, Tiny-YOLO, One-stage vs. Two-stage的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 数学狂想曲(十一)——高阶统计, 最速降
- 下一篇: 深度学习(三十六)——R-FCN, FP