This repository is dedicated to the analysis and visualization of Non-EEG biomedical data (non-EEG) through Explainable AI techniques. The goal is to provide a clear understanding of the factors that influence the predictions made by machine learning models in the domain of biomedical signal analysis.
To get a local copy up and running, follow these simple steps:
Ensure that you have the following installed:
- Python 3.6 or later
- pip (Python package installer)
-
Clone the repository:
git clone https://github.com/dheerajpr97/Explainable-AI-Non-EEG.git
-
Navigate to the cloned repository directory:
cd EXPLAINABLE-AI-NON-EEG
-
Install the necessary Python packages:
pip install -r requirements.txt
Grad-CAM is an advanced technique that helps in visualizing the regions of the input that are important for predictions from Convolutional Neural Networks (CNNs). It uses the gradients flowing into the last convolutional layer of the model to produce a heatmap highlighting the significant areas contributing to the model's decision.
Below is an example of a Grad-CAM heatmap generated for 'Physical Stress' class:
The heatmap colors range from blue (low relevance) to red (high relevance), indicating the model's focus areas for the given prediction.
streamlit run app.py
The command starts the Streamlit server and serves the Streamlit application defined in app.py for interactive use in a web browser.
This repo also includes a Dockerfile which allows you to build a Docker image of the application. This can simplify the setup and ensure consistency across different environments.
To build the Docker image, ensure you have Docker installed and then run the following command from the project's root directory:
docker build -t explainable-ai-non-eeg .
docker run -p 8501:8501 explainable-ai-non-eeg
This will start a container from the image and map port 8501 inside the container to port 8501 on your host machine. Once the container is running, you can access the Streamlit app by navigating to http://localhost:8501 in your web browser.