source: doc/python_module.rst @ 39d6fba

feature/autosinkfeature/constantqfeature/pitchshiftfeature/pydocstringsfeature/timestretch
Last change on this file since 39d6fba was 39d6fba, checked in by Paul Brossier <piem@piem.org>, 14 months ago

[doc] move python tests from python/README.md to doc/python_module.rst

  • Property mode set to 100644
File size: 1.8 KB

Installing aubio for Python

The aubio extension for Python is available for Python 2.7 and Python 3.

Installing aubio with pip

aubio can now be installed using pip:

$ pip install aubio

Building the module

From aubio source directory, run the following:

$ ./setup.py clean
$ ./setup.py build
$ sudo ./setup.py install

Double precision

This module can be compiled in double-precision mode, in which case the default type for floating-point samples will be 64-bit. The default is single precision mode (32-bit, recommended).

To build the aubio module with double precision, use the option --enable-double of the build_ext subcommand:

$ ./setup.py clean
$ ./setup.py build_ext --enable-double
$ pip install -v .

Note: If linking against libaubio, make sure the library was also compiled in :ref:`doubleprecision` mode.

?

Checking your installation

Once the python module is installed, its version can be checked with:

$ python -c "import aubio; print(aubio.version, aubio.float_type)"

The command line aubio is also installed:

$ aubio -h

Python tests

A number of Python tests are provided in the python tests. To run them, install nose2 and run the script python/tests/run_all_tests:

$ pip install nose2
$ ./python/tests/run_all_tests
Note: See TracBrowser for help on using the repository browser.