Installation#
The easiest way to install pyufunc is to install it as part of the Anaconda distribution, a cross platform distribution for data analysis and scientific computing. The Conda package manager is the recommended installation method for most users.
Python version support#
Officially Python 3.9 or higher.
Installing pyufunc#
Installing from PyPI#
pyufunc can be installed via pip from PyPI.
pip install pyufunc
Note
It is recommended to install and run pyufunc from a virtual environment, for example, using the Python standard library’s venv
Handling ImportErrors#
If you encounter an ImportError, it usually means that Python couldn’t find pyufunc in the list of available
libraries. Python internally has a list of directories it searches through, to find packages. You can
obtain these directories with.
import sys
sys.path
One way you could be encountering this error is if you have multiple Python installations on your system
and you don’t have pyufunc installed in the Python installation you’re currently using.
In Linux/Mac you can run which python on your terminal and it will tell you which Python installation you’re
using. If it’s something like “/usr/bin/python”, you’re using the Python from the system, which is not recommended.
It is highly recommended to use conda, for quick installation and for package and dependency updates.
Dependencies#
Required dependencies#
pyufunc requires no dependencies.
Optional dependencies used by specific utility functions are not installed
automatically. If a function requires a missing package, pyufunc reports the
missing dependency and skips the function call. Install the package manually, or
explicitly opt in to automatic installation where supported, for example
import_package("package-name", auto_install=True).