Browse Source

[bugfix]random sample op accu is wrong

tags/v1.3.0
lizhenyu 4 years ago
parent
commit
78329860e1
1 changed files with 4 additions and 0 deletions
  1. +4
    -0
      mindspore/ccsrc/backend/kernel_compiler/gpu/random/uniform_candidate_sampler_gpu_kernel.h

+ 4
- 0
mindspore/ccsrc/backend/kernel_compiler/gpu/random/uniform_candidate_sampler_gpu_kernel.h View File

@@ -119,6 +119,10 @@ class UniformCandidateSamplerGpuKernel : public GpuKernel {
if (init_seed_ == 0 && cur_seed_ != 0) {
cur_seed_ = 0;
}

if (init_seed_ != 0) {
generator_.seed(init_seed_);
}
}

protected:


Loading…
Cancel
Save