Commit 18197345 authored by Manuel Günther's avatar Manuel Günther
Browse files

New README and documentation strategy.

parent d1899d38
......@@ -2,6 +2,7 @@
......@@ -16,4 +17,3 @@ dist
......@@ -6,6 +6,7 @@ matrix:
- secure: U6PO13Ek4WGWqkx1g9nearxLiK9QEOp0/YcncDGtK1uTjH4poEfL4+Zdqdmusgz0ZPzEbpNdDjrVkPdzlHfMCLiD7b1F0ZXwZn8gZaQRljCFVN4gRxHHUSDuhqMCfByJe2dAai7G+NP7k2c4j+kjMMNt0L8Sg9kxPjk99ZH0EL4=
- secure: SPjDIc4Qs4FsnCUyHbsYKj8+7FmltTrFfoRBEqbYvSC6onRjfkauJEFSBkO2sTv/usa5AcKmCBjfMiqSya2/eSjJzti7d1AWHrtIe8CsU4/KtJkCT/3Y72HJk35CRpUyp/Pd3dhASjrAvI7aByU60EvRfxcwtNJEumwx0bM+OE8=
- python: 3.2
- NUMPYSPEC===1.8.0
......@@ -15,7 +16,7 @@ matrix:
- sudo add-apt-repository -y ppa:biometrics/bob
- sudo apt-get update -qq
- sudo apt-get install --force-yes libboost-all-dev libblitz1-dev libatlas-dev libatlas-base-dev liblapack-dev libhdf5-serial-dev
- sudo apt-get install --force-yes libboost-all-dev libblitz1-dev libatlas-dev libatlas-base-dev liblapack-dev libhdf5-serial-dev texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended
- if [ -n "${NUMPYSPEC}" ]; then sudo apt-get install -qq gfortran; fi
- if [ -n "${NUMPYSPEC}" ]; then pip install --upgrade pip setuptools; fi
- if [ -n "${NUMPYSPEC}" ]; then pip install --find-links --find-links --use-wheel numpy$NUMPYSPEC; fi
......@@ -2,79 +2,34 @@
.. Andre Anjos <>
.. Thu 29 Aug 2013 16:07:57 CEST
.. image::
.. image::
.. image::
.. image::
.. image::
.. image::
.. image::
.. image::
Python bindings for bob.measure
Experiment Evaluation Metrics for Bob
This package contains a set of Pythonic bindings for Bob's measure packages and
This package contains Bob's measure packages and functionality.
Install it through normal means, via PyPI or use ``zc.buildout`` to bootstrap
the package and run test units.
To install this package -- alone or together with other `Packages of Bob <>`_ -- please read the `Installation Instructions <>`_.
For Bob_ to be able to work properly, some dependent packages are required to be installed.
Please make sure that you have read the `Dependencies <>`_ for your operating system.
For further documentation on this package, please read the `Stable Version <>`_ or the `Latest Version <>`_ of the documentation.
For a list of tutorials on this or the other packages ob Bob_, or information on submitting issues, asking questions and starting discussions, please visit its website.
The latest version of the documentation can be found `here <>`_.
Otherwise, you can generate the documentation for this package yourself, after installation, using Sphinx::
$ sphinx-build -b html doc sphinx
This shall place in the directory ``sphinx``, the current version for the
documentation of the package.
You can run a set of tests using the nose test runner::
$ nosetests -sv
.. warning::
If Bob <= 1.2.1 is installed on your python path, nose will automatically
load the old version of the insulate plugin available in Bob, which will
trigger the loading of incompatible shared libraries (from Bob itself), in
to your working binary. This will cause a stack corruption. Either remove
the centrally installed version of Bob, or build your own version of Python
in which Bob <= 1.2.1 is not installed.
You can run our documentation tests using sphinx itself::
$ sphinx-build -b doctest doc sphinx
You can test overall test coverage with::
$ nosetests --with-coverage --cover-package=bob.measure
The ``coverage`` egg must be installed for this to work properly.
To develop this package, install using ``zc.buildout``, using the buildout
configuration found on the root of the package::
$ python
$ ./bin/buildout
Tweak the options in ``buildout.cfg`` to disable/enable verbosity and debug
.. _bob:
......@@ -250,36 +250,10 @@ autoclass_content = 'both'
autodoc_member_order = 'bysource'
autodoc_default_flags = ['members', 'undoc-members', 'inherited-members', 'show-inheritance']
def smaller_than(v1, v2):
"""Compares scipy/numpy version numbers"""
c1 = v1.split('.')
c2 = v2.split('.')[:len(c1)] #clip to the compared version
for i, k in enumerate(c2):
n1 = c1[i]
n2 = c2[i]
n1 = int(n1)
n2 = int(n2)
except ValueError:
n1 = str(n1)
n2 = str(n2)
if n1 > n2: return False
return True
# Some name mangling to find the correct sphinx manuals for some packages
numpy_version = __import__('numpy').version.version
if smaller_than(numpy_version, '1.5.z'):
numpy_version = '.'.join(numpy_version.split('.')[:-1]) + '.x'
numpy_version = '.'.join(numpy_version.split('.')[:-1]) + '.0'
numpy_manual = '' % numpy_version
# For inter-documentation mapping:
intersphinx_mapping = {
'' % sys.version_info[:2]: None,
numpy_manual: None,
from bob.extension.utils import link_documentation
intersphinx_mapping = link_documentation()
def setup(app):
......@@ -255,7 +255,7 @@ This will produce an image like the following one:
If you wish to reset axis zooming, you must use the Gaussian scale rather
than the visual marks showed at the plot, which are just there for
displaying purposes. The real axis scale is based on the
``bob.measure.ppndf()`` method. For example, if you wish to set the x and y
:py:func:`bob.measure.ppndf` method. For example, if you wish to set the x and y
axis to display data between 1% and 40% here is the recipe:
.. doctest::
......@@ -315,8 +315,8 @@ Full applications
We do provide a few scripts that can be used to quickly evaluate a set of
scores. We present these scripts in this section. The scripts take as input
either a 4-column or 5-column data format as specified in the documentation of
:py:mod:`bob.measure.load.four_column` or
:py:func:`bob.measure.load.four_column` or
To calculate the threshold using a certain criterion (EER, min.HTER or weighted
Error Rate) on a set, after setting up |project|, just do:
......@@ -6,7 +6,7 @@
Python API
This section includes information for using the pure Python API of ``bob::measure``.
This section includes information for using the Python API of :py:mod:`bob.measure`.
......@@ -20,7 +20,7 @@ setup(
description='Bindings for bob.measure',
description='Bob\'s evalution metrics',
author='Andre Anjos',
......@@ -74,7 +74,8 @@ setup(
classifiers = [
'Development Status :: 3 - Alpha',
'Framework :: Bob',
'Development Status :: 4 - Beta',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Natural Language :: English',
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment