fatf.transparency.sklearn.tools.is_sklearn_model_instance

fatf.transparency.sklearn.tools.is_sklearn_model_instance(clf)[source]

Checks whether a class instance (object) is a scikit-learn predictor.

New in version 0.0.2.

This function is similar to fatf.transparency.sklearn.tools.is_sklearn_model but it enforces the clf to be an instance of an object in addition to checking whether it inherits from sklearn.base.BaseEstimator.

Parameters
clfobject

A Python object (class instance) to be checked.

Returns
is_valid_modelboolean

True if the object inherits from sklearn.base.BaseEstimator, False otherwise.