Scikit-Explain Documentation
scikit-explain is a user-friendly Python module for machine learning explainability. For a comprehensive tutorial, see Flora et al. (2024).
Current explainability products include:
- Feature Importance:
Single- and Multi-pass Permutation Importance (Breiman et al. 2001; Lakshmanan et al. 2015; McGovern et al. 2019)
First-order PD/ALE Variance (Greenwell et al. 2018)
Grouped Permutation Importance (Au et al. 2021)
- Feature Effects/Attributions:
Partial Dependence (PD)
Individual Conditional Expectations (ICE)
Random forest-based feature contributions (TreeInterpreter)
- Feature Interactions:
Second-order PD/ALE
Interaction Strength (IAS) and Main Effect Complexity (MEC) (Molnar et al. 2019)
Friedman H-statistic (Friedman and Popescu 2008)
Sobol Indices
A primary feature of scikit-explain is the accompanying plotting methods, which are designed to be easy to use while producing publication-quality figures. Computations leverage parallelization when possible.
The package is under active development. Feel free to raise issues!
Citation
If you employ scikit-explain in your research, please cite:
@article{Flora_2024,
author = {Flora, Montgomery L. and McGovern, Amy and Handler, Shawn},
title = {A Machine Learning Explainability Tutorial for Atmospheric Sciences},
journal = {Artificial Intelligence for the Earth Systems},
volume = {3},
number = {1},
pages = {e230018},
year = {2024},
doi = {10.1175/AIES-D-23-0018.1},
url = {https://journals.ametsoc.org/view/journals/aies/3/1/AIES-D-23-0018.1.xml}
}
Installation
pip (PyPI):
pip install scikit-explain
conda (conda-forge):
conda install -c conda-forge scikit-explain
Development version (most up-to-date):
git clone https://github.com/monte-flora/scikit-explain.git
cd scikit-explain
pip install -e .
Tutorials
Contribute
Issue Tracker: https://github.com/monte-flora/scikit-explain/issues
Source Code: https://github.com/monte-flora/scikit-explain
Support
If you are having issues, please let us know. We have a mailing list located at: monte.flora@noaa.gov
License
The project is licensed under the BSD license.