<< this->layer_param_.window_data_param().crop_mode();
// image
- int crop_size = this->layer_param_.window_data_param().crop_size();
+ const int crop_size = this->transform_param_.crop_size();
CHECK_GT(crop_size, 0);
const int batch_size = this->layer_param_.window_data_param().batch_size();
- (*top)[0]->Reshape(batch_size, channels, crop_size, crop_size);
+ top[0]->Reshape(batch_size, channels, crop_size, crop_size);
this->prefetch_data_.Reshape(batch_size, channels, crop_size, crop_size);
- LOG(INFO) << "output data size: " << (*top)[0]->num() << ","
- << (*top)[0]->channels() << "," << (*top)[0]->height() << ","
- << (*top)[0]->width();
+ 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_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();
+ top[0]->channels() * top[0]->height() * top[0]->width();
// label
- (*top)[1]->Reshape(batch_size, 1, 1, 1);
+ top[1]->Reshape(batch_size, 1, 1, 1);
this->prefetch_label_.Reshape(batch_size, 1, 1, 1);
}