Skip to content

Latest commit

 

History

History
67 lines (41 loc) · 1.94 KB

README.md

File metadata and controls

67 lines (41 loc) · 1.94 KB

Python C Extensions Tutorial

How to use?

# Python 2.x example
python setup.py build
python setup.py install
python test.py

Or,

# Python 2.x example
python setup.py build

# copy .so file from the ./build/lib.XXX/myModule.so folder to current folder

python test.py

Python 3:

Python 2

Python 2 & 3

Numpy

Building for CUDA support

Cext folder

This is a sample code borrowed from following link:

https://scipy-cookbook.readthedocs.io/items/C_Extensions_NumPy_arrays.html