summaryrefslogtreecommitdiff
path: root/src/caffe
diff options
context:
space:
mode:
authorJeff Donahue <jeff.donahue@gmail.com>2015-10-05 14:15:08 -0700
committerJeff Donahue <jeff.donahue@gmail.com>2015-10-05 14:15:08 -0700
commit64f948a6829c53031632d87f78183dd87d5d6f71 (patch)
tree6fe89242040659eee3c595621a0800d8a4324330 /src/caffe
parent92dc4e6aae9118c3a7cc7572782ffc87534aec96 (diff)
downloadcaffeonacl-64f948a6829c53031632d87f78183dd87d5d6f71.tar.gz
caffeonacl-64f948a6829c53031632d87f78183dd87d5d6f71.tar.bz2
caffeonacl-64f948a6829c53031632d87f78183dd87d5d6f71.zip
SilenceLayer Backward bugfix (fixes #3151)
Diffstat (limited to 'src/caffe')
-rw-r--r--src/caffe/layers/silence_layer.cpp2
-rw-r--r--src/caffe/layers/silence_layer.cu2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/caffe/layers/silence_layer.cpp b/src/caffe/layers/silence_layer.cpp
index 4abf9eff..7e70ab43 100644
--- a/src/caffe/layers/silence_layer.cpp
+++ b/src/caffe/layers/silence_layer.cpp
@@ -12,7 +12,7 @@ void SilenceLayer<Dtype>::Backward_cpu(const vector<Blob<Dtype>*>& top,
for (int i = 0; i < bottom.size(); ++i) {
if (propagate_down[i]) {
caffe_set(bottom[i]->count(), Dtype(0),
- bottom[i]->mutable_cpu_data());
+ bottom[i]->mutable_cpu_diff());
}
}
}
diff --git a/src/caffe/layers/silence_layer.cu b/src/caffe/layers/silence_layer.cu
index 8d044ee7..34faef22 100644
--- a/src/caffe/layers/silence_layer.cu
+++ b/src/caffe/layers/silence_layer.cu
@@ -18,7 +18,7 @@ void SilenceLayer<Dtype>::Backward_gpu(const vector<Blob<Dtype>*>& top,
for (int i = 0; i < bottom.size(); ++i) {
if (propagate_down[i]) {
caffe_gpu_set(bottom[i]->count(), Dtype(0),
- bottom[i]->mutable_gpu_data());
+ bottom[i]->mutable_gpu_diff());
}
}
}