forked from mindspore-Ecosystem/mindspore
!23910 Fix blank in Cdist API.
Merge pull request !23910 from liuxiao93/code_docs_Cdist-api
This commit is contained in:
commit
ff18208473
|
@ -1065,30 +1065,30 @@ class CumProd(PrimitiveWithInfer):
|
|||
|
||||
class Cdist(Primitive):
|
||||
"""
|
||||
Computes batched the p norm distance between each pair of the two collections of row vectors.
|
||||
Computes batched the p norm distance between each pair of the two collections of row vectors.
|
||||
|
||||
Args:
|
||||
p (float): P value for the p norm distance to calculate between each vector pair ∈[0,∞].
|
||||
p (float): P value for the p norm distance to calculate between each vector pair ∈[0,∞].
|
||||
|
||||
Inputs:
|
||||
- **input_x** (Tensor) - Input tensor of shape :math:`(B, P, M)`.
|
||||
- **input_x** (Tensor) - Input tensor of shape :math:`(B, P, M)`.
|
||||
Letter :math:`B` represents 0 or positive int number.
|
||||
When :math:`B` is equal to 0, it means this dimension can be ignored,
|
||||
i.e. shape of the tensor is :math:`(P, M)`.
|
||||
- **input_y** (Tensor) - Input tensor of shape :math:`(B, R, M)`.
|
||||
- **input_y** (Tensor) - Input tensor of shape :math:`(B, R, M)`.
|
||||
|
||||
Outputs:
|
||||
Tensor, has the same dtype as `input_x`, which shape is :math:`(B, P, R)`.
|
||||
Tensor, has the same dtype as `input_x`, which shape is :math:`(B, P, R)`.
|
||||
|
||||
Raises:
|
||||
TypeError: If `input_x` or `input_y` is not a Tensor.
|
||||
TypeError: If dtype of `input_x` or `input_y` is neither float16 nor float32.
|
||||
TypeError: If `p` is not a float.
|
||||
TypeError: If `input_x` or `input_y` is not a Tensor.
|
||||
TypeError: If dtype of `input_x` or `input_y` is neither float16 nor float32.
|
||||
TypeError: If `p` is not a float.
|
||||
ValueError: If `p` is a negative float.
|
||||
ValueError: If dimension of `input_x` is not the same as `input_y`.
|
||||
ValueError: If dimension of `input_x` or `input_y` is neither 2 or 3.
|
||||
|
||||
Supported Platforms:
|
||||
Supported Platforms:
|
||||
``Ascend``
|
||||
|
||||
Examples:
|
||||
|
|
Loading…
Reference in New Issue