From 05c5d2918f6870359c1dfd9f27c66e1d0ce0e8f2 Mon Sep 17 00:00:00 2001 From: zhangyi Date: Wed, 23 Sep 2020 10:53:39 +0800 Subject: [PATCH] fix the format of api comments. --- mindspore/common/seed.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/mindspore/common/seed.py b/mindspore/common/seed.py index 44cfcdecda..484e81015f 100644 --- a/mindspore/common/seed.py +++ b/mindspore/common/seed.py @@ -30,12 +30,14 @@ def set_seed(seed): Note: The global seed is used by numpy.random, mindspore.common.Initializer, mindspore.ops.composite.random_ops and - mindspore.nn.probability.distribution. + mindspore.nn.probability.distribution. + If global seed is not set, these packages will use their own default seed independently, numpy.random and - mindspore.common.Initializer will choose a random seed, mindspore.ops.composite.random_ops and - mindspore.nn.probability.distribution will use zero. + mindspore.common.Initializer will choose a random seed, mindspore.ops.composite.random_ops and + mindspore.nn.probability.distribution will use zero. + Seed set by numpy.random.seed() only used by numpy.random, while seed set by this API will also used by - numpy.random, so just set all seed by this API is recommended. + numpy.random, so just set all seed by this API is recommended. Args: seed (int): The seed to be set.