You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by gi...@git.apache.org on 2017/08/03 00:42:05 UTC

[GitHub] piiswrong commented on a change in pull request #7303: add backward(is_train=False) and always mode for dropout

piiswrong commented on a change in pull request #7303: add backward(is_train=False) and always mode for dropout
URL: https://github.com/apache/incubator-mxnet/pull/7303#discussion_r131031091
 
 

 ##########
 File path: src/operator/dropout-inl.h
 ##########
 @@ -96,7 +104,7 @@ class DropoutOp : public Operator {
       bernoulli_generate(count, this->pkeep_, maskptr);
   #pragma omp parallel for
       for (int i = 0; i < count; ++i) {
-        outptr[i] = dataptr[i] * maskptr[i];
+        outptr[i] = dataptr[i] * maskptr[i] * (1.0f / pkeep_);
 
 Review comment:
   @zhenlinluo @ykim362 
   MKL dropout has been wrong the whole time!
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services