(转载自:WikiPedia)

Fine tuning is a process to take a network model that has already been trained for a given task, and make it perform a second similar task.

Assuming the original task is similar to the new task, using a network that has already been designed & trained allows us to take advantage of the feature extraction that happens in the front layers of the network without developing that feature extraction network from scratch. Fine tuning:

  • Replaces the output layer, originally trained to recognize (in the case of imagenet models) 1,000 classes, with a layer that recognizes the number of classes you require
  • The new output layer that is attached to the model is then trained to take the lower level features from the front of the network and map them to the desired output classes, using SGD
  • Once this has been done, other late layers in the model can be set as 'trainable=True' so that in further SGD epochs their weights can be fine-tuned for the new task too.

More detail here.

With respect to the cats vs dogs example:

  • The original task would be classifying the images into the 1000s of Imagenet categories.
  • The new task would be to classify the images into just 2 categories i.e., cats or dogs.
  • From the definition of finetune, the last layer is removed/popped.
  • Trainable is set to false for all other lower layers as they have already been trained (as part of the original task)
  • In order for the trainable false to take effect, the model needs to be compiled again, as per the last line in the vgg16.finetune() function.

Fine Tuning的更多相关文章

  1. (原)caffe中fine tuning及使用snapshot时的sh命令

    转载请注明出处: http://www.cnblogs.com/darkknightzh/p/5946041.html 参考网址: http://caffe.berkeleyvision.org/tu ...

  2. L23模型微调fine tuning

    resnet185352 链接:https://pan.baidu.com/s/1EZs9XVUjUf1MzaKYbJlcSA 提取码:axd1 9.2 微调 在前面的一些章节中,我们介绍了如何在只有 ...

  3. PHP 5.6 编译安装选项说明

    `configure' configures this package to adapt to many kinds of systems. Usage: ./configure [OPTION].. ...

  4. Ubuntu下的MySQL安装

    <1>安装mysql-server sudo apt-get update sudo apt-get install mysql-server mysql-client <2> ...

  5. MAGENTO - APACHE SOLR INTEGRATION - PART II (SETUP)

    MAGENTO - APACHE SOLR INTEGRATION - PART II (SETUP) Tue, 03/01/2011 - 18:30 Tweet Development E-Comm ...

  6. debian C++ OTL库 用 unixodbc 连接 mysql 小记

    这个东东也是折腾了几天,网上很多文章可能已经过时,所以写下不同,以备后用. 参考网址: http://blog.csdn.net/genganpeng/article/details/7402229 ...

  7. php7 httpd 2.4 编译

    1.获取源码httpd-2.4.23.tar.gz   php-7.1.0.tar.gz,安装顺序必须是先安装http然后php,lnmp同理   2.安装编译环境和php.httpd依赖包,红色字体 ...

  8. centos 7 编译zabbix 3.2.2

    已有LNMP环境. 1.安装zabbix需要的依赖包,红色部门的包官方yum源没有,需要自己下载 yum install net-snmp fping iksemel net-snmp-devel   ...

  9. A very cool thing: Install MYSQL from source without root access on LINUX

    最近由于工作的需要,要在centos上安装MYSQL服务器.作为一名小兵中的小兵,当然是没有root权限的,为了能够使用mysql,只能使用源码安装了(因为binary安装方式似乎需要root acc ...

随机推荐

  1. Collatz 序列、逗号代码、字符图网格

    1.collatz序列 编写一个名为 collatz()的函数,它有一个名为 number 的参数.如果参数是偶数, 那么 collatz()就打印出 number // 2,并返回该值.如果 num ...

  2. jmeter简单使用示例

    1.下载后解压,运行bin目录下的jmeter.bat 2.add ThreadGroup 3.add request 4.add listener

  3. MySql中存储引擎MyISAM与InnoDB区别于选择

    InnoDB: 支持事务处理等 不加锁读取 支持外键 支持行锁 不支持FULLTEXT类型的索引 不保存表的具体行数,扫描表来计算有多少行 DELETE 表时,是一行一行的删除 InnoDB 把数据和 ...

  4. 用户登录时,获取用户ip地址

    使用django来获取用户访问的IP地址,如果用户是正常情况下通过request.META['REMOTE_ADDR']  可以获得用户的IP地址.但是有些网站服务器会使用ngix等代理http,或者 ...

  5. sql server query to get the list of column name in a table

    --SQL Server 2005, 2008 or 2012: SELECT * FROM information_schema.tables --SQL Server 2000: SELECT * ...

  6. javascript 文字大小自动适应文本框 (文字大小自动调整)

    javascript 文字大小自动适应文本框 (文字大小自动调整) TOC 思考 思考一:面积法 思考二:微调法 代码 在进行类似微博墙之类的展示页面中,经常会遇到这样的需求:在固定大小的区域放入字数 ...

  7. C语言实现整数数组的逆置算法

    读入100个整数到一个数组中,写出实现该数组进行逆置的算法. 方法一: 假设100个整数读入到数组a中,算法f1的思想是分别从数组两端依次将对应数进行交换,即a[i]与a[100 - i - 1]进行 ...

  8. mongodb学习总结

    安装mongodb: 1.下载服务器最新稳定版本(选择偶数号的版本号),mongodb的版本管理偶数号为稳定版,奇数号为开发版. 2.安装时默认安装在c盘,可以选择自定义选项来改变安装路径. 3.安装 ...

  9. 从尾到头打印链表(C++和Python 实现)

    (说明:本博客中的题目.题目详细说明及参考代码均摘自 “何海涛<剑指Offer:名企面试官精讲典型编程题>2012年”) 题目 输入一个链表的头结点, 从尾到头反过来打印出每个结点的值. ...

  10. tcp-full.cc

    ns2--tcp-full.cc /* -*- Mode:C++; c-basic-offset:8; tab-width:8; indent-tabs-mode:t -*- */ /* * Copy ...