caffe调loss方法
正文
what should I do if...
...my loss diverges? (increases by order of magnitude, goes to inf. or NaN)
lower the learning rate
raise momentum (with corresponding learning rate drop)
raise weight decay
raise batch size
use gradient clipping (limit the L2 norm of the gradient to a particular value at each iteration; shrink it to that norm if greater)
try another solver: momentum SGD, ADAM, RMSProp, ...
try a smaller initialization (e.g., for a Gaussian init., lower the stdev.)
what should I do if...
...my loss doesn’t improve / gets stuck / drops slowly?
- raise the learning rate
 - (maybe) lower momentum, weight decay, and/or batch size
 - try another solver: momentum SGD, ADAM, RMSProp, ...
 - transfer a pre-trained (e.g. on ImageNet) initialization, if possible
 - use a larger initialization (in particular, make sure you didn’t zero-initialize any multiplicative weights in intermediate layers)
 use a “smarter” initialization (e.g., for linear layers followed by ReLUs, try the msra initialization in Caffe)
remove some layers to make the network shallower
at least to start!
a strategy for model design: begin with a simple, trainable network; “deepen” it by adding new layers one-by-one
-modify the architecture to improve gradient flow:
batch normalization
residual learning [ResNet]
intermediate losses [GoogLeNet]
other tricks
be patient! (go outside?)
deep learning can take a long time
training AlexNet in 2012: 12 days
although this is down to 1 day in 2015!
loss hovers around the chance value of ln(1000) ≅ 6.908 for the first 1000+ iterations (~1 hour on 2012 GPU)
training ResNet-152 in 2015: 1-2 months (on 8 GPUs!)
the best configurations (net architectures, solvers) at convergence are often not the ones that train fastest early on
some tricks to speed up learning can be “greedy” rather than ultimately beneficial
补充一个:如果显存不够,考虑设定iter_size来增大batch_size
reference
caffe调loss方法的更多相关文章
- JVM垃圾回收机制总结:调优方法
		
转载: JVM垃圾回收机制总结:调优方法 JVM 优化经验总结 JVM 垃圾回收器工作原理及使用实例介绍
 - JVM调优总结:调优方法
		
JVM调优总结:调优方法 2012-01-10 14:35 和你在一起 和你在一起的博客 字号:T | T 下面文章将讲解JVM的调优工具以及如何去调优等等问题,还有一些异常问题的处理.详细请看下文. ...
 - Web app 的性能瓶颈与性能调优方法
		
1. web app 性能测试工具使用 2. mysql 性能分析与调优方法
 - 性能测试培训:tomcat性能调优方法
		
性能测试培训:tomcat性能调优方法 poptest是国内唯一一家培养测试开发工程师的培训机构,以学员能胜任自动化测试,性能测试,测试工具开发等工作为目标.在poptest的loadrunner ...
 - LightGBM 调参方法(具体操作)
		
sklearn实战-乳腺癌细胞数据挖掘(博主亲自录制视频) https://study.163.com/course/introduction.htm?courseId=1005269003& ...
 - disruptor调优方法
		
翻译自disruptor在github上的文档,https://github.com/LMAX-Exchange/disruptor/wiki/Getting-Started Basic Tuning ...
 - JVM调优方法
		
目 录 目 录 I 诠释JVM调优 1 第1章 JVM内存模型及垃圾收集算法 1 1.1 根据Java虚拟机规范,JVM将内存划分为 1 1.2 垃圾回收算法 1 第2章 内存泄漏及解决方法 2 2. ...
 - 无刷电调修理方法 | 银燕(EMAX)12A无刷电调维修
		
一. 银燕(XP-12A)电调修理 笔者的电调在使用4S电池时烧毁,其中一个PMOS管明显烧焦. 将其拆除,买来新元件重新焊接,通电依然冒烟了. 引脚定义 丝印662F: XC6206P332MR 低 ...
 - Python中Gradient Boosting Machine(GBM)调参方法详解
		
原文地址:Complete Guide to Parameter Tuning in Gradient Boosting (GBM) in Python by Aarshay Jain 原文翻译与校对 ...
 
随机推荐
- ROS 可视化(一): 发布PointCloud2点云数据到Rviz
			
1. 相关依赖package.xml 需要添加对 pcl_ros 包的依赖 2. CMakeLists.txt find_package(PCL REQUIRED) include_directori ...
 - SpringBoot单元测试示例
			
⒈控制器Action示例 package cn.coreqi.controller; import org.junit.Test; import org.junit.runner.RunWith; i ...
 - HttpResonse 要记得关闭
			
写了一个小程序,要识别网站上的图片,用到HttpRequest发请求,HttpResponse接受返回数据.刚开始循环可以跑两个,但是总是提示超时.后来查资料发现,在Http协议中,规定了同个Http ...
 - bzoj 1175: The stairways of Saharna
			
一道杨氏矩阵的题,萌新初入门,还不是很懂,这篇 blog 讲的超级好(就是看图有点麻烦) 据说这玩意儿可以代替堆和平衡树用,支持插入.删除.查询,跑得还挺快的(慢着,复杂度好像是 n^2 ? 而且空间 ...
 - codeforces 955F  Cowmpany Cowmpensation 树上DP+多项式插值
			
给一个树,每个点的权值为正整数,且不能超过自己的父节点,根节点的最高权值不超过D 问一共有多少种分配工资的方式? 题解: A immediate simple observation is that ...
 - Docker的离线安装
			
由于公司需要离线部署Docker,这里将其步骤记录下来. 目标环境Centos7.2. 由于目标环境为公司内网,首先尝试在https://download.docker.com/linux/cento ...
 - $Django Rest Framework-认证组件,权限组件 知识点回顾choices,on_delete
			
一 小知识点回顾 #orm class UserInfo (models.Model): id = models.AutoField (primary_key=True) name = models. ...
 - I/O 模型
			
5种I/O模型的基本区别: 阻塞式I/O 非阻塞式I/O I/O复用 信号异步模型 异步I/O 1. 阻塞 I/O 最流行的I/O模型是阻塞I/O模型,缺省情形下,所有套接口都是阻塞的.我们以数据报套 ...
 - Confluence 6 导入一个 Confluence 站点
			
有下面 2 种类方法可以导入一个站点 - 通过上传一个文件或者从你 Confluence 服务器上读取一个目录.上传文件仅仅是针对一个小站点的情况.为了取得最好的导入结果,我们推荐你从服务器上的目录上 ...
 - mysql通配符使用
			
mysql通配符使用: w3cchool 在mysql查询中,经常会用到通配符,而且mysql的通配符和pgsql是有所不同的,甚至mysql中还可以使用正则表达式.本文就为大家带来mysql查询中通 ...