预告:
Face recognition
Style transfer
Quiz
先收藏一下这门课的简介:
http://baijiahao.baidu.com/s?id=1575792471896118&wfr=spider&for=pc
相关的笔记收藏:
http://blog.csdn.net/koala_tree/article/details/78597575
今天学习一下吴恩达深度学习系列课的第四课第4周的课程。
内容包括两部分:face recognition和style transfer.
先看face recognition部分:
验证和识别的差别。后者的难度更大,需要一次人脸验证的正确率能达到99.9%以上。因为每一次若是99%的正确率,乘以多次以后,正确率会显著下降。
![](https://img.haomeiwen.com/i5040713/775d9dc2363a4858.png)
Screen Shot 2017-11-27 at 6.11.23 PM.png
下面提出了siamese net的概念:就是让两个输入分别经过参数一模一样的模型,得到各自的编码,然后再计算编码的“差距”。
我们的愿望是让不是同一个人的两张照片,上述“差距”尽可能大;相反,尽可能小。
![](https://img.haomeiwen.com/i5040713/4d083eacacc712e4.png)
Screen Shot 2017-11-27 at 7.09.54 PM.png
![](https://img.haomeiwen.com/i5040713/a8359fc75a5e21aa.png)
Screen Shot 2017-11-27 at 7.11.31 PM.png
wiki上关于siamese net的介绍:
![](https://img.haomeiwen.com/i5040713/d9f27930cb25a7e1.jpeg)
siamese.jpeg
注意:comtrastive loss function
![](https://img.haomeiwen.com/i5040713/a70a54634b74a584.png)
Screen Shot 2017-11-27 at 7.16.11 PM.png
![](https://img.haomeiwen.com/i5040713/28aab586460d8efe.png)
Screen Shot 2017-11-27 at 7.22.27 PM.png
![](https://img.haomeiwen.com/i5040713/44b65a93d4ef53ba.png)
Screen Shot 2017-11-27 at 7.02.00 PM.png
![](https://img.haomeiwen.com/i5040713/53f6fffaed06132a.png)
Screen Shot 2017-11-27 at 7.24.53 PM.png
L的表达式得到以后,还是用Gradient Descent来学习得到d(img1,img2)的模型:
(f是带着卷积网络的参数的,这些参数就是training要得到的目标)
![](https://img.haomeiwen.com/i5040713/59bfca84043781b0.png)
Screen Shot 2017-11-27 at 7.25.47 PM.png
![](https://img.haomeiwen.com/i5040713/599779bef23a66e4.png)
Screen Shot 2017-11-27 at 7.28.03 PM.png
除了上面的loss function,还有一种看待问题的方式或者角度:
![](https://img.haomeiwen.com/i5040713/87dbc74cfb937f2a.png)
Screen Shot 2017-11-27 at 8.07.59 PM.png
![](https://img.haomeiwen.com/i5040713/1798b9fbd17e00e2.png)
Screen Shot 2017-11-27 at 8.10.08 PM.png
这个week第二部分的内容是style transfer:
首先他讲了对图片卷积神经网络的过程中,每一层所得的结果到底是什么样子的。
Unit 指的就是一个filter。越属于浅层的filter,它一次卷积运算前所扫过的窗口,只能看到整张图片的很小的一部分,所以它识别的是很微观的东西。比如如图所示的,左上右下的斜线。
![](https://img.haomeiwen.com/i5040713/2705e0d6c1b102f3.png)
Screen Shot 2017-11-27 at 9.20.38 PM.png
![](https://img.haomeiwen.com/i5040713/2bcf5b4bb6ac6aea.png)
Screen Shot 2017-11-27 at 9.21.04 PM.png
而越在网络深层的filter,它一次扫过,所覆盖到的原图的像素越多,它能做到相对宏观的侦测,比如某个filter可以是猫或狗的detector。这也是QUIZ第6题的答案。
![](https://img.haomeiwen.com/i5040713/1e314f0d4ed979ac.png)
Screen Shot 2017-11-27 at 9.24.02 PM.png
![](https://img.haomeiwen.com/i5040713/baf7639cfd21903f.png)
Screen Shot 2017-11-27 at 9.24.09 PM.png
然后开始讲如何做style transfer:
![](https://img.haomeiwen.com/i5040713/76973070e0387499.png)
Screen Shot 2017-11-27 at 9.32.27 PM.png
![](https://img.haomeiwen.com/i5040713/3b79e8387ce8557b.png)
Screen Shot 2017-11-27 at 9.33.38 PM.png
Quiz同时也是一个很好的学习小结:
![](https://img.haomeiwen.com/i5040713/b4dddd20e6eec171.png)
Screen Shot 2017-11-27 at 9.55.27 PM.png
![](https://img.haomeiwen.com/i5040713/ca498f4cdced4fd6.png)
Screen Shot 2017-11-27 at 9.55.36 PM.png
![](https://img.haomeiwen.com/i5040713/de7c11bc3618fee8.png)
Screen Shot 2017-11-27 at 9.55.44 PM.png
![](https://img.haomeiwen.com/i5040713/c2ed55b79249897e.png)
Screen Shot 2017-11-27 at 9.55.52 PM.png
![](https://img.haomeiwen.com/i5040713/af7bb4a43a35a62d.png)
Screen Shot 2017-11-27 at 9.56.00 PM.png
![](https://img.haomeiwen.com/i5040713/73a381d770601087.png)
Screen Shot 2017-11-27 at 9.56.08 PM.png