You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by GitBox <gi...@apache.org> on 2019/03/20 01:13:32 UTC

[GitHub] [incubator-mxnet] yuxihu commented on a change in pull request #14397: Add exception handling support for waitall

yuxihu commented on a change in pull request #14397: Add exception handling support for waitall
URL: https://github.com/apache/incubator-mxnet/pull/14397#discussion_r267154685
 
 

 ##########
 File path: src/resource.cc
 ##########
 @@ -190,12 +190,14 @@ class ResourceManagerImpl : public ResourceManager {
     cpu_rand_->Seed(seed);
     cpu_parallel_rand_->Seed(seed);
 #if MXNET_USE_CUDA
-    gpu_rand_.Get(ctx.dev_id, [ctx, seed, this]() {
-      return new ResourceRandom<gpu>(ctx, seed);
-    })->Seed(seed);
-    gpu_parallel_rand_.Get(ctx.dev_id, [ctx, seed, this]() {
-      return new ResourceParallelRandom<gpu>(ctx, gpu_native_rand_copy_, seed);
-    })->Seed(seed);
+    if (ctx != Context::CPU()) {
 
 Review comment:
   Was this a bug? Shall we check ctx == Context::GPU()? There are other non-GPU context.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services