Arraylias Documentation#
Arraylias is an open-source Python library providing single-dispatching tools centred around the construction of an aliased module. Aliased modules are built by initially registering “libraries” consisting of a collection of types, then registering different versions of a given function in the aliased module for each underlying type library. When using the aliased module, function calls are automatically dispatched to version of the function for the correct library based on the type of the first argument.
Arraylias contains default pre-built aliased versions of both NumPy and SciPy, with additional registration of the JAX and Tensorflow array libraries. This enables writing NumPy and SciPy like code that will that will execute on NumPy, JAX, and Tensorflow array objects as if it had been written in the respective native libraries. If necessary, these default aliases can be further extended to fit the needs of the application.
Warning
This package is still in the early stages of development and it is very likely that there will be breaking API changes in future releases. If you encounter any bugs please open an issue on Github