mindspore.ops.ScalarCast

View Source On Gitee
class mindspore.ops.ScalarCast[source]

‘ops.ScalarCast’ is deprecated from version 2.3 and will be removed in a future version, please use int(x) or float(x) instead.

Supported Platforms:

Deprecated

Examples

>>> import mindspore
>>> from mindspore import ops
>>> scalar_cast = ops.ScalarCast()
>>> output = scalar_cast(255.0, mindspore.int64)
>>> print(output)
255