sponge.function.get_ndarray

View Source On Gitee
sponge.function.get_ndarray(value: Union[Tensor, Parameter, ndarray, List[float], Tuple[float]], dtype: type = None)[source]

get ndarray type of the input value

Parameters
  • value (Union[Tensor, Parameter, ndarray, List[float], Tuple[float]]) – Input value

  • dtype (type) – Data type. Default: None.

Returns

array (ndarray)

Supported Platforms:

Ascend GPU CPU