Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion include/caffe/layers/base_conv_layer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,9 @@ class BaseConvolutionLayer : public Layer<Dtype> {
int col_offset_;
int output_offset_;

Blob<Dtype> col_buffer_;
// N.B. sharing the col buffer reduces memory but interferes with
// ND conv and parallelism
static Blob<Dtype> col_buffer_;
Blob<Dtype> bias_multiplier_;
};

Expand Down
3 changes: 3 additions & 0 deletions src/caffe/layers/base_conv_layer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@

namespace caffe {

template <typename Dtype>
Blob<Dtype> BaseConvolutionLayer<Dtype>::col_buffer_;

template <typename Dtype>
void BaseConvolutionLayer<Dtype>::LayerSetUp(const vector<Blob<Dtype>*>& bottom,
const vector<Blob<Dtype>*>& top) {
Expand Down