Skip to content

Bessouat40/python-ai-explainability

Repository files navigation

python AI explainability

A python project to find anomaly in an Xray image.

The aim is detect pneumonia in a thorax radiography and explain AI decision.

Training data source : database link

Model

I use a VGG16 model.

M1 use

You need to create a conda environment to increase your training performances :

source ~/.zshrc
conda create -n tf_m1 python=3.11
conda activate tf_m1
conda install -c apple tensorflow-deps
pip install tensorflow-macos
pip install tensorflow-metal

Training

First create .env file :

mv .env.example .env

Then fill .env file with your values.

In your conda env :

python train.py

Training results with test set

-------------------- Dataset Summary --------------------

Number of train images :  4684


Number of test images :  586


Number of validation images :  586


Shape of each images :  (224, 224, 3)
---------------------------------------------------------

loss: 0.0611 - accuracy: 0.9795

Results

output output2

Tensorboard

Source : tensorboard-doc

For python notebook

%load_ext tensorboard
%tensorboard --logdir logs/fit

About

A python project to find anomaly in an Xray image.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published