From 6201591ac761847ec87ef4c4a259017368f87211 Mon Sep 17 00:00:00 2001 From: Amir MOHAMMADI <amir.mohammadi@idiap.ch> Date: Mon, 12 Jun 2017 10:53:38 +0200 Subject: [PATCH] Fix sphinx problems --- bob/bio/base/utils/io.py | 14 +++++++------- doc/py_api.rst | 1 + 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/bob/bio/base/utils/io.py b/bob/bio/base/utils/io.py index f8dcddcc..d1f43cb9 100644 --- a/bob/bio/base/utils/io.py +++ b/bob/bio/base/utils/io.py @@ -190,7 +190,7 @@ def _generate_features(reader, paths): Yields ------ object - The first object returned is the :py:type:`numpy.dtype` of features. The + The first object returned is the :py:class:`numpy.dtype` of features. The second objects returned is the shape of the first feature. The rest of objects are the actual values in features. The features are returned in C order. @@ -272,11 +272,11 @@ def vstack_features(reader, paths, same_size=False): ---------- reader : collections.Callable The function to load the features. The function should only take one - argument being the path to the features. Use :py:type:`functools.partial` - to accommodate your reader to this format. The features returned by - ``reader`` are expected to have the same :py:type:`numpy.dtype` and the - same shape except for their first dimension. First dimension is should - correspond to the number of samples. + argument being the path to the features. Use + :any:`functools.partial` to accommodate your reader to this format. + The features returned by ``reader`` are expected to have the same + :py:class:`numpy.dtype` and the same shape except for their first + dimension. First dimension is should correspond to the number of samples. paths : collections.Iterable An iterable of paths to iterate on. Whatever is inside path is given to ``reader``. If ``same_size`` is ``True``, ``len(paths)`` must be valid. @@ -288,7 +288,7 @@ def vstack_features(reader, paths, same_size=False): Returns ------- numpy.ndarray - The read features with the shape (n_samples, *features_shape[1:]). + The read features with the shape (n_samples, \*features_shape[1:]). """ iterable = _generate_features(reader, paths) dtype = next(iterable) diff --git a/doc/py_api.rst b/doc/py_api.rst index a43beead..cd2f90f3 100644 --- a/doc/py_api.rst +++ b/doc/py_api.rst @@ -17,6 +17,7 @@ IO-related functions bob.bio.base.open_compressed bob.bio.base.close_compressed bob.bio.base.check_file + bob.bio.base.vstack_features Functions dealing with resources -- GitLab