| 12 | |
| 13 | template <typename Dtype> |
| 14 | void SigmoidLayer<Dtype>::Forward_cpu(const vector<Blob<Dtype>*>& bottom, |
| 15 | const vector<Blob<Dtype>*>& top) { |
| 16 | const Dtype* bottom_data = bottom[0]->cpu_data(); |
| 17 | Dtype* top_data = top[0]->mutable_cpu_data(); |
| 18 | const int count = bottom[0]->count(); |
| 19 | for (int i = 0; i < count; ++i) { |
| 20 | top_data[i] = sigmoid(bottom_data[i]); |
| 21 | } |
| 22 | } |
| 23 | |
| 24 | template <typename Dtype> |
| 25 | void SigmoidLayer<Dtype>::Backward_cpu(const vector<Blob<Dtype>*>& top, |
nothing calls this directly
no test coverage detected