summaryrefslogtreecommitdiff
path: root/src/caffe
diff options
context:
space:
mode:
authorphilkr <philkr@users.noreply.github.com>2015-09-01 13:11:26 -0700
committerphilkr <philkr@users.noreply.github.com>2015-09-01 13:11:26 -0700
commita6751723234926bdd03b6167ea6414da109854a3 (patch)
tree391e289e669898fff5229abc45b9d95f7c4d71a8 /src/caffe
parentd362894887af9dca8581906b2284f5be81dbd403 (diff)
downloadcaffeonacl-a6751723234926bdd03b6167ea6414da109854a3.tar.gz
caffeonacl-a6751723234926bdd03b6167ea6414da109854a3.tar.bz2
caffeonacl-a6751723234926bdd03b6167ea6414da109854a3.zip
Compute backward for negative lr_mult
Diffstat (limited to 'src/caffe')
-rw-r--r--src/caffe/net.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/caffe/net.cpp b/src/caffe/net.cpp
index f1fc63ab..89d14013 100644
--- a/src/caffe/net.cpp
+++ b/src/caffe/net.cpp
@@ -182,7 +182,7 @@ void Net<Dtype>::Init(const NetParameter& in_param) {
for (int param_id = 0; param_id < num_param_blobs; ++param_id) {
const ParamSpec* param_spec = (param_id < param_size) ?
&layer_param.param(param_id) : &default_param_spec;
- const bool param_need_backward = param_spec->lr_mult() > 0;
+ const bool param_need_backward = param_spec->lr_mult() != 0;
need_backward |= param_need_backward;
layers_[layer_id]->set_param_propagate_down(param_id,
param_need_backward);