NumCu#
Numerical CUDA-based Python library built on top of CuVec.
Install#
pip install numcu
Requirements:
- Python 3.7 or greater (e.g. via Anaconda or Miniconda or via
python3-dev
) - (optional) CUDA SDK/Toolkit (including drivers for an NVIDIA GPU)
- note that if the CUDA SDK/Toolkit is installed after NumCu, then NumCu must be re-installed to enable CUDA support
Usage#
import numcu as nc
import numpy as np
a = nc.zeros((1337, 42), "float32")
assert isinstance(cu.zeros(1), np.ndarray)
b = nc.ones_like(a)
assert np.all(nc.div(a, b) == 0)