skcuda.misc.subtract(x_gpu, y_gpu)[source]

Subtracts two scalars, vectors, or matrices with broadcasting.

The numpy broadcasting rules apply so this would yield the same result as x_gpu.get() - y_gpu.get() in host code.

Parameters:y_gpu (x_gpu,) – The arrays to be subtracted.
Returns:out – Equivalent to x_gpu.get() - y_gpu.get().
Return type:pycuda.gpuarray.GPUArray


The out and stream options are not supported because GPUArray.__sub__ doesn’t provide them.