-
According to the note on figuring out the model type, it is recommended to use However, since the attribute Thanks for your input! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
If one employs $ git grep -E "( |\.)is_classifier"
doc/developers/develop.rst:like :func:`base.is_classifier` should be used.
doc/glossary.rst: checked by way of a helper such as :func:`base.is_classifier`.
doc/glossary.rst: :func:`~base.is_classifier`.
doc/glossary.rst: is a classifier (determined by :func:`base.is_classifier`) and the
doc/modules/classes.rst: base.is_classifier
sklearn/base.py:def is_classifier(estimator):
... but nothing for $ git grep -E "( |\.)is_clusterer" There is no corresponding function for clusterer. def is_clusterer(estimator):
return getattr(estimator, "_estimator_type", None) == "clusterer" |
Beta Was this translation helpful? Give feedback.
If one employs
git grep
to browse the repository, one finds a lot foris_classifier
:but nothing for
is_clusterer
:There is no corresponding function for clusterer.
I'm afraid, you need to add your own function …