Does the dropout layer need to be defined in deploy.prototxt in caffe?

筅森魡賤 提交于 2019-12-05 16:58:36

Yes. Dropout is not required during Testing.

Even if you include a dropout layer, nothing special happens during Testing. See the source code of dropout forward pass:

  if (this->phase_ == TRAIN) {
    // Code to do something
  } else {
    caffe_copy(bottom[0]->count(), bottom_data, top_data);  //Code to copy bottom blob to top blob
  }

As seen in the source code, the bottom blob data is copied to top blob data memory if its not on Training phase.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!