roywei opened a new pull request #17547: Fix cudnn Dropout reproducibility
URL: https://github.com/apache/incubator-mxnet/pull/17547
 
 
   Fix https://github.com/apache/incubator-mxnet/issues/15662
   This will replace #16532 with an alternative solution.
   Please refer to the discussion in  
https://github.com/apache/incubator-mxnet/pull/16532#discussion_r339268855
   
   1. Added `GetSeed()` in GPU random resource, it's similar to CPU version.
   2. During cudnn dropout, check whether random seed has been changed and 
reset cudnn dropout descriptor's seed if random seed changed.
   
   Benefit:
   1. This avoided generating a random int (tensor on gpu) on GPU, copy to CPU 
and and pass it to `cudnnDropoutGetStatesSize`.
   2. get the seed from gpu random resource is fast, we can afford to do it 
every forward.
   
   Drawback:
   Will be affected by https://github.com/apache/incubator-mxnet/issues/7410, 
by default mxnet's random seed is fixed.
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to