From 6d4802ff4ab2e93562f47db44a211e03ef002bdc Mon Sep 17 00:00:00 2001 From: Paul Brossier Date: Wed, 31 Oct 2018 17:12:21 +0100 Subject: [PATCH] [doc] add a note about building the module in double precision --- doc/py_datatypes.rst | 4 ++-- doc/py_utils.rst | 2 +- doc/python_module.rst | 23 +++++++++++++++++++++++ doc/requirements.rst | 5 ++++- 4 files changed, 30 insertions(+), 4 deletions(-) diff --git a/doc/py_datatypes.rst b/doc/py_datatypes.rst index feae020b..21fad692 100644 --- a/doc/py_datatypes.rst +++ b/doc/py_datatypes.rst @@ -17,8 +17,8 @@ This section contains the documentation for :data:`float_type`, Defaults to `"float32"`. If `aubio` was built specifically with the option `--enable-double`, this - string will be defined to `"float64"`. See :ref:`doubleprecision` in - :ref:`requirements` for more details on building aubio in double + string will be defined to `"float64"`. See :ref:`py-doubleprecision` in + :ref:`python-install` for more details on building aubio in double precision mode. .. rubric:: Examples diff --git a/doc/py_utils.rst b/doc/py_utils.rst index f96784e6..6d19c0b4 100644 --- a/doc/py_utils.rst +++ b/doc/py_utils.rst @@ -4,7 +4,7 @@ Utilities --------- -This section documents various helpers functions included in the aubio library. +This section documents various helper functions included in the aubio library. Note name conversion .................... diff --git a/doc/python_module.rst b/doc/python_module.rst index e008a315..cb4d595e 100644 --- a/doc/python_module.rst +++ b/doc/python_module.rst @@ -25,6 +25,29 @@ From ``aubio`` source directory, run the following: $ ./setup.py build $ sudo ./setup.py install + +.. _py-doubleprecision: + +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: + +.. code:: bash + + $ ./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 -------------------------- diff --git a/doc/requirements.rst b/doc/requirements.rst index 22308ebc..078f7c68 100644 --- a/doc/requirements.rst +++ b/doc/requirements.rst @@ -297,12 +297,15 @@ Here is an example of a custom command: --manpagesdir=/opt/share/man \ uninstall clean distclean dist distcheck +.. _doubleprecision: + Double precision ................ To compile aubio in double precision mode, configure with ``--enable-double``. -To compile aubio in single precision mode, use ``--disable-double`` (default). +To compile aubio in single precision mode, use ``--disable-double`` (default, +recommended). Disabling the tests ................... -- 2.11.0