Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
bob
bob.pipelines
Commits
60c67792
Commit
60c67792
authored
Nov 09, 2020
by
Amir MOHAMMADI
Browse files
Merge branch 'conda-recipe-numpy-conflict' into 'master'
Fix sphinx warnings See merge request
!44
parents
3975182c
cb7069f1
Pipeline
#45141
passed with stages
in 5 minutes and 4 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
bob/pipelines/wrappers.py
View file @
60c67792
...
...
@@ -4,6 +4,7 @@ import os
from
functools
import
partial
import
bob.io.base
import
cloudpickle
import
dask.bag
...
...
@@ -13,8 +14,6 @@ from sklearn.base import MetaEstimatorMixin
from
sklearn.base
import
TransformerMixin
from
sklearn.pipeline
import
Pipeline
import
bob.io.base
from
.sample
import
DelayedSample
from
.sample
import
SampleBatch
from
.sample
import
SampleSet
...
...
@@ -84,13 +83,10 @@ class SampleWrapper(BaseWrapper, TransformerMixin):
Do not use this class except for scikit-learn estimators.
.. todo::
Also implement ``predict``, ``predict_proba``, and ``score``. See:
https://scikit-learn.org/stable/developers/develop.html#apis-of-scikit-learn-objects
Attributes
----------
estimator
The scikit-learn estimator that is wrapped.
fit_extra_arguments : [tuple]
Use this option if you want to pass extra arguments to the fit method of the
mixed instance. The format is a list of two value tuples. The first value in
...
...
@@ -99,14 +95,14 @@ class SampleWrapper(BaseWrapper, TransformerMixin):
passing samples to the fit method and want to pass ``subject`` attributes of
samples as the ``y`` argument to the fit method, you can provide ``[("y",
"subject")]`` as the value for this attribute.
transform_extra_arguments : [tuple]
Similar to ``fit_extra_arguments`` but for the transform and other similar methods.
output_attribute: str
output_attribute : str
The name of a Sample attribute where the output of the estimator will be
saved to. [Default is ``data``]
Example:
if ``output_attribute`` is ``"annotations"``, then
``sample.annotations`` will contain the output of the estimator.
saved to [Default is ``data``]. For example, if ``output_attribute`` is
``"annotations"``, then ``sample.annotations`` will contain the output of
the estimator.
transform_extra_arguments : [tuple]
Similar to ``fit_extra_arguments`` but for the transform and other similar
methods.
"""
def
__init__
(
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment