Skip to content

XAI-Analytics is a tool that opens the black-box of machine learning. It helps the user to understand the decision-making process of machine learning models.

License

Notifications You must be signed in to change notification settings

Batev/XAI-Analytics

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Binder

XAI-Analytics

XAI-Analytics is a tool that opens the black-box of machine learning. It makes model interpretability easy. XAI-Analytics offers a wide range of features such as data visualization, data preprocessing, ML-model training and global and local ML-model interpreting. The interactive Jupyter Notebook offers an user-friendly interface that gives the user full control over the tool. For a quick demo of XAI-Analytics jump to the demo section. For examples please refer to examples.

Getting started

Run on binder

  1. Start the binder notebook server by clicking here
  2. Run XAI-Analytics.ipynb notebook file

Run locally

  1. Clone the XAI-Analytics repository: https://github.com/Batev/XAI-Analytics.git

  2. Navigate to checkout directory in Bash or Powershell and ...

    • Unix

      # (Optional) Create a new virtual environment 
      $> python3 -m venv venv
      # Start the virtual environment, e.g. venv
      $> source venv/bin/activate
      # Install project requirements
      $> pip3 install -r requirements.txt
      # Modules with outdated dependencies (e.g. Skater on wordcloud==1.3.1), that are erroneous when installed with pip. 
      $> pip3 install --no-dependencies --no-cache-dir -r requirements-no-deps.txt 
      # Skater only supports scikit-learn<=0.22.2.post1 but other modules require scikit-learn>=0.23.1, therefore this workaround is necessary.
      $> find . -name 'tree_visualizer.py' -exec sed -i 's/from sklearn.externals.six import StringIO/from six import StringIO/g' {} +
      # Start notebook server
      $> jupyter notebook
    • Windows (PowerShell)

      # (Optional) Create a new virtual environment 
      $> python -m venv venv
      # Start the virtual environment, e.g. venv
      $> set-executionpolicy RemoteSigned -Scope CurrentUser
      $> .\venv\Scripts\activate
      # Install project requirements
      $> pip install -r requirements.txt
      # Modules with outdated dependencies (e.g. Skater on wordcloud==1.3.1), that are erroneous when installed with pip.  
      $> pip install --no-dependencies --no-cache-dir -r requirements-no-deps.txt
      # Skater only supports scikit-learn<=0.22.2.post1 but other modules require scikit-learn>=0.23.1, therefore this workaround is necessary. If you use python 3.7 or 3.8 the path to skater should be adjusted accordingly, e.g. ...skater-1.1.2-py3.9.egg...
      $> (Get-Content venv\Lib\site-packages\skater-1.1.2-py3.9.egg\skater\core\visualizer\tree_visualizer.py) | %{$_ -replace "from sklearn.externals.six import StringIO", "from six import StringIO"} | Set-Content venv\Lib\site-packages\skater-1.1.2-py3.9.egg\skater\core\visualizer\tree_visualizer.py
      # Start notebook server
      $> jupyter notebook
  3. Default browser will be started in current directory

  4. Run XAI-Analytics.ipynb notebook file

Prerequisites

  • Python >= 3.7* and <= 3.9*
  • Microsoft Visual C++ > 14.0 (Windows only)

Please refer to the requirements file for a list of the python module prerequisites. The file excludes XAI, Skater and PDPbox because of incompatible versions in the dependencies when started with binder. The requirements.txt is auto-generated from requirements.in (which consists of the raw dependencies) using pip-compile. For using locally with all required modules please refer to the Run locally step.

Demo

v1.0

Demo

Examples

Example notebooks can be found in examples. Quick HTML overview of the example notebooks:

Known Issues

TODO

  • Add XAI-Analytics to A gallery of interesting Jupyter Notebooks when ALPHA version is released.
  • Add auto-generated adversarial examples to some dataset.
  • Fix XGBoost interpretations bug.
  • Add option for removing features from a dataset in the preprocessing step.
  • Add option for normalizing/removing unknown values from a dataset in the preprocessing step.
  • Add custom exceptions and raise them where needed.
  • Improve logging -> do not show info messages in the notebooks, use display instead. Add more debug messages.

Non-Goals

  • Support for semi-supervised, unsupervised and reinforcement learning.
  • Model interpretation of regression algorithms.

Creators

This project was created by Evgeni Batev under the supervision of Ao.univ.Prof. Dr. Andreas Rauber at the Vienna University of Technology.

License

BSD 3-Clause License

About

XAI-Analytics is a tool that opens the black-box of machine learning. It helps the user to understand the decision-making process of machine learning models.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published