MCPcopy Create free account
hub / github.com/BVLC/caffe / Reshape

Method Reshape

src/caffe/layers/prelu_layer.cpp:55–64  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

53
54template <typename Dtype>
55void PReLULayer<Dtype>::Reshape(const vector<Blob<Dtype>*>& bottom,
56 const vector<Blob<Dtype>*>& top) {
57 CHECK_GE(bottom[0]->num_axes(), 2)
58 << "Number of axes of bottom blob must be >=2.";
59 top[0]->ReshapeLike(*bottom[0]);
60 if (bottom[0] == top[0]) {
61 // For in-place computation
62 bottom_memory_.ReshapeLike(*bottom[0]);
63 }
64}
65
66template <typename Dtype>
67void PReLULayer<Dtype>::Forward_cpu(const vector<Blob<Dtype>*>& bottom,

Callers 1

LayerSetUpMethod · 0.45

Calls 2

num_axesMethod · 0.80
ReshapeLikeMethod · 0.80

Tested by

no test coverage detected