sklearn-instrumentation Documentation

actions rtd pypi pyversions

Generalized instrumentation tooling for scikit-learn models. sklearn_instrumentation allows instrumenting the sklearn package and any scikit-learn compatible packages with estimators and transformers inheriting from sklearn.base.BaseEstimator.

Instrumentation works by applying decorators to methods of BaseEstimator-derived classes or instances. By default the instrumentor applies instrumentation to the following methods (except when they are properties of instances):

  • fit

  • fit_transform

  • predict

  • predict_log_proba

  • predict_proba

  • transform

  • _fit

  • _fit_transform

  • _predict

  • _predict_log_proba

  • _predict_proba

  • _transform

sklearn-instrumentation supports instrumentation of full sklearn-compatible packages, as well as recursive instrumentation of models (metaestimators like Pipeline, or even single estimators like RandomForestClassifier)

Indices and tables