Skip to content

cunumpy

Install from PyPI with

Terminal window
pip install cunumpy

Simple wrapper for numpy and cupy. Replace import numpy as np with import cunumpy as xp.

Example usage:

Terminal window
export ARRAY_BACKEND=cupy
import cunumpy as xp
arr = xp.array([1,2])
print(type(arr))
print(xp.__version__)

Check out the code on GitHub!

Links: