diff --git a/docs/api/api_python/ops/mindspore.ops.func_clip_by_value.rst b/docs/api/api_python/ops/mindspore.ops.func_clip_by_value.rst index d06954773b0..d43ddea3689 100644 --- a/docs/api/api_python/ops/mindspore.ops.func_clip_by_value.rst +++ b/docs/api/api_python/ops/mindspore.ops.func_clip_by_value.rst @@ -17,11 +17,11 @@ .. note:: - `clip_value_min` 必须小于或等于 `clip_value_max` ; - - :math:`x` , `clip_value_min` 和 `clip_value_max`的数据类型需支持隐式类型转换,且不能同时为布尔型。 + - :math:`x` , `clip_value_min` 和 `clip_value_max` 的数据类型需支持隐式类型转换,且不能同时为布尔型。 参数: - - **x** (Tensor) - clip_by_value的输入,任意维度的Tensor。 + - **x** (Tensor) - `clip_by_value` 的输入,任意维度的Tensor。 - **clip_value_min** (Tensor) - 指定最小值。 - **clip_value_max** (Tensor) - 指定最大值。 diff --git a/mindspore/python/mindspore/nn/metrics/error.py b/mindspore/python/mindspore/nn/metrics/error.py index e8b2a534610..6fef606e23f 100644 --- a/mindspore/python/mindspore/nn/metrics/error.py +++ b/mindspore/python/mindspore/nn/metrics/error.py @@ -28,7 +28,7 @@ class MAE(Metric): in the input: :math:`x` and the target: :math:`y`. .. math:: - \text{MAE} = \frac{\sum_{i=1}^n \|y_{pred}_i - y_i\|}{n} + \text{MAE} = \frac{\sum_{i=1}^n \|{y\_pred}_i - y_i\|}{n} where :math:`n` is batch size. @@ -104,7 +104,7 @@ class MSE(Metric): each element in the prediction and the ground truth: :math:`x` and: :math:`y`. .. math:: - \text{MSE}(x,\ y) = \frac{\sum_{i=1}^n(y_{pred}_i - y_i)^2}{n} + \text{MSE}(x,\ y) = \frac{\sum_{i=1}^n({y\_pred}_i - y_i)^2}{n} where :math:`n` is batch size. diff --git a/mindspore/python/mindspore/nn/metrics/roc.py b/mindspore/python/mindspore/nn/metrics/roc.py index 02e032c4161..1d3aa0a849c 100644 --- a/mindspore/python/mindspore/nn/metrics/roc.py +++ b/mindspore/python/mindspore/nn/metrics/roc.py @@ -169,11 +169,11 @@ class ROC(Metric): A tuple, composed of `fpr`, `tpr`, and `thresholds`. - **fpr** (np.array) - False positive rate. In binary classification case, a fpr numpy array under different - thresholds will be returned, otherwise in multiclass case, a list of - fpr numpy arrays will be returned and each element represents one category. + thresholds will be returned, otherwise in multiclass case, a list of + fpr numpy arrays will be returned and each element represents one category. - **tpr** (np.array) - True positive rates. n binary classification case, a tps numpy array under different - thresholds will be returned, otherwise in multiclass case, a list of tps numpy arrays - will be returned and each element represents one category. + thresholds will be returned, otherwise in multiclass case, a list of tps numpy arrays + will be returned and each element represents one category. - **thresholds** (np.array) - Thresholds used for computing fpr and tpr. Raises: diff --git a/mindspore/python/mindspore/nn/probability/distribution/uniform.py b/mindspore/python/mindspore/nn/probability/distribution/uniform.py index 90a1e1f5982..4029bd2993e 100644 --- a/mindspore/python/mindspore/nn/probability/distribution/uniform.py +++ b/mindspore/python/mindspore/nn/probability/distribution/uniform.py @@ -30,7 +30,7 @@ class Uniform(Distribution): and the probability density function: .. math:: - f(x, a, b) = 1 / b \exp(\exp(-(x - a) / b) - x), + f(x, a, b) = 1 / (b - a), where a and b are the lower and upper bound respectively.