diff --git a/bob/bio/base/extractor/Linearize.py b/bob/bio/base/extractor/Linearize.py index 27c5ea23821a6a0b14ffaca5f746bb8e506ff7c3..d854303ec75892711164839c2078586c3a5d5c41 100644 --- a/bob/bio/base/extractor/Linearize.py +++ b/bob/bio/base/extractor/Linearize.py @@ -32,7 +32,7 @@ class Linearize(Extractor): data : 1D :py:class:`numpy.ndarray` The extracted feature vector, of the desired ``dtype`` (if specified). - """ + """ assert isinstance(data, numpy.ndarray) linear = numpy.reshape(data, data.size) diff --git a/bob/bio/base/transformers/preprocessor.py b/bob/bio/base/transformers/preprocessor.py index f91c563cfd8c060531d814e6a40cf13a56cfb7d0..03f1e150ab58fd29b6717c833d887ef3dc9b5bf5 100644 --- a/bob/bio/base/transformers/preprocessor.py +++ b/bob/bio/base/transformers/preprocessor.py @@ -4,6 +4,7 @@ from sklearn.base import TransformerMixin, BaseEstimator from bob.bio.base.preprocessor import Preprocessor + class PreprocessorTransformer(TransformerMixin, BaseEstimator): """ Scikit learn transformer for :any:`bob.bio.base.preprocessor.Preprocessor`. @@ -18,13 +19,13 @@ class PreprocessorTransformer(TransformerMixin, BaseEstimator): """ def __init__( - self, - instance, - **kwargs, + self, instance, **kwargs, ): if not isinstance(instance, Preprocessor): - raise ValueError("`instance` should be an instance of `bob.bio.base.preprocessor.Preprocessor`") + raise ValueError( + "`instance` should be an instance of `bob.bio.base.preprocessor.Preprocessor`" + ) self.instance = instance super().__init__(**kwargs)