ArrayFire Python Wrapper
Project description
arrayfire-binary-python-wrapper
ArrayFire is a high performance library for parallel computing with an easy-to-use API. It enables users to write scientific computing code that is portable across CUDA, OpenCL and CPU devices.
This project is meant to provide thin Python bindings for the ArrayFire C library. It also decouples releases of the main C/C++ library from the Python library by acting as a intermediate library and only wrapping the provided C calls.
This allows the building of large binary wheels only when the underlying ArrayFire version is increased, and the fully-featured Python library can be developed atop independently. The package is not intended to be used directly and merely exposes the C functionality required by downstream implementations. This package can exist in two forms, with a bundled binary distribution, or merely as a loader that will load the ArrayFire library from a system or user level install.
Installing
The arrayfire-binary-python-wrapper can be installed from a variety of sources. Pre-built wheels are available for a number of systems and toolkits. These will include a binary distribution of the ArrayFire libraries. Installing from PyPI directly will only include a wrapper-only, source distribution that will not contain binaries. In this case, wrapper-only installations will require a separate installation of the ArrayFire C/C++ libraries. You can get the ArrayFire C/C++ library from the following sources:
Install the last stable version of python wrapper:
pip install arrayfire-binary-python-wrapper
Install a pre-built wheel:
pip install arrayfire-binary-python-wrapper -f https://repo.arrayfire.com/python/wheels/3.9.0/
Building
The arrayfire-binary-python-wrapper can build wheels in packaged-binary or in system-wrapper modes. scikit-build-core is used to provide the python build backend. The minimal, wrapper-only mode that relies on a system install will be built by default though the regular python build process. For example:
pipx run build --wheel
Building a full pre-packaged local binary is an involved process that will require referencing the regular ArrayFire build procedures.
Besides the regular ArrayFire CMake configuration, building the binaries is an opt-in process that is set by an environment variable AF_BUILD_LOCAL_LIBS=1
. Once that environment variable is set, scikit-build-core will take care of cloning ArrayFire, building, and including the necessary binaries.
Contributing
The community of ArrayFire developers invites you to build with us if you are interested and able to write top-performing tensor functions. Together we can fulfill The ArrayFire Mission for fast scientific computing for all.
Contributions of any kind are welcome! Please refer to the wiki and our Code of Conduct to learn more about how you can get involved with the ArrayFire Community through Sponsorship, Developer Commits, or Governance.
Citations and Acknowledgements
If you redistribute ArrayFire, please follow the terms established in the license.
ArrayFire development is funded by AccelerEyes LLC and several third parties, please see the list of acknowledgements for an expression of our gratitude.
Support and Contact Info
- Slack Chat
- Google Groups
- ArrayFire Services: Consulting | Support | Training
Trademark Policy
The literal mark "ArrayFire" and ArrayFire logos are trademarks of AccelerEyes LLC (dba ArrayFire). If you wish to use either of these marks in your own project, please consult ArrayFire's Trademark Policy
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file arrayfire_binary_python_wrapper-0.7.0.tar.gz
.
File metadata
- Download URL: arrayfire_binary_python_wrapper-0.7.0.tar.gz
- Upload date:
- Size: 67.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | af550fe6001147610aa67188c5e076c01a736386181a45c963db80a8b08df493 |
|
MD5 | ad23ee1e61730587ee60280742f9b3d5 |
|
BLAKE2b-256 | fe907b27549981b3947676056e19defe1b20b85ada46ffcc89e0c18ff1c3f661 |
File details
Details for the file arrayfire_binary_python_wrapper-0.7.0-py3-none-manylinux_2_28_x86_64.whl
.
File metadata
- Download URL: arrayfire_binary_python_wrapper-0.7.0-py3-none-manylinux_2_28_x86_64.whl
- Upload date:
- Size: 77.3 kB
- Tags: Python 3, manylinux: glibc 2.28+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4dbbb9f9a15a7c618140b093037681b2568da7855a85b2a45fe8cc3c9d9951e4 |
|
MD5 | c5e59d0e7b17d2927e3c710f2031b6b6 |
|
BLAKE2b-256 | 38088fc405850c48b5eecfff316120434711fc44e17fa21c23516a71062eb813 |