Skip to content

Latest commit

 

History

10 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

oclpy

oclpy is an experimental, GPU-first implementation of the Python Array API standard using pyclesperanto as its device backend.

pip install oclpy
import oclpy as xp

x = xp.asarray([[1, 2], [3, 4]], dtype=xp.float32)
y = xp.ones((2, 2), dtype=xp.float32)
print(xp.add(x, y))

The initial release implements creation, elementwise arithmetic and comparisons, dtype handling, reductions, matrix multiplication, and basic manipulation. Operations stay on the selected pyclesperanto device; conversion to NumPy is explicit through xp.asnumpy().

Development

pip install -e ".[test]"
pytest

Tests use a small in-memory pyclesperanto-compatible backend, so the core API can be validated on machines without a GPU. tests/test_pyclesperanto_smoke.py is the real-device integration test and skips when no backend/device is available.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages