cupy.can_cast#

cupy.can_cast(from_, to, casting='safe')[source]#

Returns True if cast between data types can occur according to the casting rule. If from is a scalar or array scalar, also returns True if the scalar value can be cast without overflow or truncation to an integer.

See also

numpy.can_cast()