参考链接:http://blog.csdn.net/lingerlanlan/article/details/32329761

RNN神经网络:http://nbviewer.ipython.org/github/BVLC/caffe/blob/master/examples/detection.ipynb

官方链接:http://nbviewer.ipython.org/github/BVLC/caffe/blob/master/examples/classification.ipynb

参考链接:http://suanfazu.com/t/caffe-shen-du-xue-xi-kuang-jia-shang-shou-jiao-cheng/281/3

模型定义中有一点比较容易被误解,信号在有向图中是自下而上流动的,并不是自上而下。

层的结构定义如下:

1
name:层名称 2
type:层类型 3
top:出口 4 bottom:入口

Each layer type defines three critical computations: setup, forward, andbackward.

  • Setup: initialize the layer and its connections once at model initialization.
  • Forward: given input from bottom compute the output and send to the top.
  • Backward: given the gradient w.r.t. the top output compute the gradient w.r.t. to the input and send to the bottom. A layer with parameters computes the gradient w.r.t. to its parameters and stores it internally.

/home/wishchin/caffe-master/examples/hdf5_classification/train_val2.prototxt

name: "LogisticRegressionNet"
layer {
name: "data"
type: "HDF5Data"
top: "data"
top: "label"
include {
phase: TRAIN
}
hdf5_data_param {
source: "hdf5_classification/data/train.txt"
batch_size: 10
}
}
layer {
name: "data"
type: "HDF5Data"
top: "data"
top: "label"
include {
phase: TEST
}
hdf5_data_param {
source: "hdf5_classification/data/test.txt"
batch_size: 10
}
}
layer {
name: "fc1"
type: "InnerProduct"
bottom: "data"
top: "fc1"
param {
lr_mult: 1
decay_mult: 1
}
param {
lr_mult: 2
decay_mult: 0
}
inner_product_param {
num_output: 40
weight_filler {
type: "gaussian"
std: 0.01
}
bias_filler {
type: "constant"
value: 0
}
}
}
layer {
name: "relu1"
type: "ReLU"
bottom: "fc1"
top: "fc1"
}
layer {
name: "fc2"
type: "InnerProduct"
bottom: "fc1"
top: "fc2"
param {
lr_mult: 1
decay_mult: 1
}
param {
lr_mult: 2
decay_mult: 0
}
inner_product_param {
num_output: 2
weight_filler {
type: "gaussian"
std: 0.01
}
bias_filler {
type: "constant"
value: 0
}
}
}
layer {
name: "loss"
type: "SoftmaxWithLoss"
bottom: "fc2"
bottom: "label"
top: "loss"
}
layer {
name: "accuracy"
type: "Accuracy"
bottom: "fc2"
bottom: "label"
top: "accuracy"
include {
phase: TEST
}
}

关于参数与结果的关系:多次训练效果一直在0.7,后来改动了全链接层的初始化参数。高斯分布的标准差由0.001改为0.0001,就是调小了。
我的结果有点相似。

最新文章

  1. Json.Net 数据解析
  2. 用vs2008打开vs2012项目
  3. mybatis 插入日期类型精确到秒的有关问题
  4. 实例源码--Android手机狗(防盗)源码
  5. opencv学习笔记(02)——遍历图像(指针法)
  6. Node.js权威指南 (8) - 创建HTTP与HTTPS服务器及客户端
  7. 关于Javascript语言中this关键字(变量)的用法
  8. HTML5 Canvas 填充与描边(Fill And Stroke)
  9. osx launchpad删除图标
  10. 第6章 影响 MySQL Server 性能的相关因素
  11. Oracle02——oracle分页、子查询、集合运算、处理数据、创建和管理表和其他数据库对象
  12. JUnit单元测试教程(翻译自Java Code Geeks)
  13. UOJ #449. 【集训队作业2018】喂鸽子
  14. 痞子衡嵌入式:ARM Cortex-M文件那些事(4)- 可重定向文件(.o/.a)
  15. python3 + selenium 之元素定位
  16. SSH 公钥登录
  17. 云服务器 ECS Linux 系统安装图形化桌面 (centos7 ubuntu14)
  18. mongodb int字段的一个小坑
  19. redhat系统下三种主要的软件包安装方法
  20. TCP的那些事-2

热门文章

  1. Labview学习笔记(二)
  2. android自定义dialog布局
  3. Python——Numpy基础知识(一)
  4. AtCoder ABC 070D - Transit Tree Path
  5. Java代码规范和一些常见问题
  6. springMVC知识点复习
  7. asp.net--webconfg指南
  8. POJ 3080 Blue Jeans (后缀数组)
  9. 【cl】maven新建web项目
  10. 【转】selenium自动化测试环境搭建