Skip to content

Commit

Permalink
Merge pull request BVLC#1091 from ronghanghu/fix_window_data_layer
Browse files Browse the repository at this point in the history
set up datum size for WindowDataLayer
  • Loading branch information
jeffdonahue committed Sep 16, 2014
2 parents 0120476 + 06d7310 commit 4b1f53c
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/caffe/layers/window_data_layer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,12 @@ void WindowDataLayer<Dtype>::DataLayerSetUp(const vector<Blob<Dtype>*>& bottom,
LOG(INFO) << "output data size: " << (*top)[0]->num() << ","
<< (*top)[0]->channels() << "," << (*top)[0]->height() << ","
<< (*top)[0]->width();
// datum size
this->datum_channels_ = (*top)[0]->channels();
this->datum_height_ = (*top)[0]->height();
this->datum_width_ = (*top)[0]->width();
this->datum_size_ =
(*top)[0]->channels() * (*top)[0]->height() * (*top)[0]->width();
// label
(*top)[1]->Reshape(batch_size, 1, 1, 1);
this->prefetch_label_.Reshape(batch_size, 1, 1, 1);
Expand Down

0 comments on commit 4b1f53c

Please sign in to comment.