Explainable AI Tooling (XAI). XAI is used to discover and explain a model's prediction in a way that is interpretable to the user. Relevant information in the dataset, feature-set, and model's algorithms are exposed.
APACHE-2.0 License
This repository provides tools for data scientists and MLOps engineers that have requirements specific to AI model interpretability.
The Intel Explainable AI Tools are designed to help users detect and mitigate against issues of fairness and interpretability, while running best on Intel hardware. There are two Python* components in the repository:
apt-get install build-essential python3-dev
Use these instructions to install the Intel AI Safety python library with a clone of the GitHub repository. This can be done instead of the basic pip install, if you plan on making code changes.
Clone this repo and navigate to the repo directory.
Allow poetry to create virtual envionment contained in .venv
directory of current directory.
poetry lock
In addtion, you can explicitly tell poetry which python instance to use
poetry env use /full/path/to/python
Choose the intel_ai_safety
subpackages and plugins that you wish to install.
a. Install intel_ai_safety
with all of its subpackages (e.g. explainer
and model_card_gen
) and plugins
poetry install --extras all
b. Install intel_ai_safety
with just explainer
poetry install --extras explainer
c. Install intel_ai_safety
with just model_card_gen
poetry install --extras model-card
d. Install intel_ai_safety
with explainer
and all of its plugins
poetry install --extras explainer-all
e. Install intel_ai_safety
with explainer
and just its pytorch implementations
poetry install --extras explainer-pytorch
f. Install intel_ai_safety
with explainer
and just its tensroflow implementations
poetry install --extras explainer-tensorflow
Activate the environment:
source .venv/bin/activate
We encourage you to use a python virtual environment (virtualenv or conda) for consistent package management. There are two ways to do this:
Choose a virtual enviornment to use:
a. Using virtualenv
:
python3 -m virtualenv xai_env
source xai_env/bin/activate
b. Or conda
:
conda create --name xai_env python=3.9
conda activate xai_env
Install to current enviornment
poetry config virtualenvs.create false && poetry install --extras all
Notebooks may require additional dependencies listed in their associated documentation.
Verify that your installation was successful by using the following commands, which display the Explainer and Model Card Generator versions:
python -c "from intel_ai_safety.explainer import version; print(version.__version__)"
python -c "from intel_ai_safety.model_card_gen import version; print(version.__version__)"
The following links have Jupyter* notebooks showing how to use the Explainer and Model Card Generator APIs in various ML domains and use cases:
The Intel Explainable AI Tools team tracks bugs and enhancement requests using GitHub issues. Before submitting a suggestion or bug report, search the existing GitHub issues to see if your issue has already been reported.
*Other names and brands may be claimed as the property of others. Trademarks
These scripts are not intended for benchmarking Intel platforms. For any performance and/or benchmarking information on specific Intel platforms, visit https://www.intel.ai/blog.
Intel is committed to the respect of human rights and avoiding complicity in human rights abuses, a policy reflected in the Intel Global Human Rights Principles. Accordingly, by accessing the Intel material on this platform you agree that you will not use the material in a product or application that causes or contributes to a violation of an internationally recognized human right.
Intel® Explainable AI Tools is licensed under Apache License Version 2.0.
To the extent that any data, datasets, or models are referenced by Intel or accessed using tools or code on this site such data, datasets and models are provided by the third party indicated as the source of such content. Intel does not create the data, datasets, or models, provide a license to any third-party data, datasets, or models referenced, and does not warrant their accuracy or quality. By accessing such data, dataset(s) or model(s) you agree to the terms associated with that content and that your use complies with the applicable license. DATASETS
Intel expressly disclaims the accuracy, adequacy, or completeness of any data, datasets or models, and is not liable for any errors, omissions, or defects in such content, or for any reliance thereon. Intel also expressly disclaims any warranty of non-infringement with respect to such data, dataset(s), or model(s). Intel is not liable for any liability or damages relating to your use of such data, datasets, or models.