cupyx.scipy.get_array_module#
- cupyx.scipy.get_array_module(*args)[source]#
Returns the array module for arguments.
This function is used to implement CPU/GPU generic code. If at least one of the arguments is a
cupy.ndarray
object, thecupyx.scipy
module is returned.- Parameters
args – Values to determine whether NumPy or CuPy should be used.
- Returns
cupyx.scipy
orscipy
is returned based on the types of the arguments.- Return type
module