Alzheimer Detection Using CNN

Alzheimer Detection Using CNN
Photo by Killian López on Dribbble

Alzheimer’s disease is a degenerative condition in which dementia symptoms grow over time. Memory loss is minimal in the early stages of Alzheimer’s, but people with late-stage Alzheimer’s lose their capacity to converse and respond to their surroundings.

There are 7 different stages of Alzheimer:

  • Stage 1: Normal Outward Behavior.
  • Stage 2: Very Mild Changes.
  • Stage 3: Mild Decline.
  • Stage 4: Moderate Decline.
  • Stage 5: Moderately Severe Decline.
  • Stage 6: Severe Decline.
  • Stage 7: Very Severe Decline.

In this article, we have explained how Alzheimer’s can be detected at an early age using Convolutional Neural Networks.

Table of Contents:


>Data Preparation

>Image Preprocessing

>Model Training

>Model Evaluation

>Graph Plot

>Model Prediction


The dataset is available on Kaggle which was given by Sarvesh Dubey

Basically ,the data is splitted into 2 types, test and train data. There were 5121 images in training set and 1279 in testing set. The images provided in the set were mostly quite clear and well formatted.

There are in all 4 labels which we need to predict.

  1. Mild Dementia,
  2. Moderate Dementia
  3. Non Dementia
  4. Very Mild Dementia

Data Preparation:

The training and test set were already present in the dataset. However, the validation set was missing. So we had to split the training data set into 80:20 ratio ie (4097 for training and 1024 for validation).

Image Processing:

By definition, Image Processing is a method to perform some operations on an image ,in order to get an enhanced image or to extract some useful information from it. It is a type of signal processing in which input is an image and output may be image or characteristics/features associated with that image.

Rescaling :

Since ,the image size has a maximum pixel of 255 ,i.e it has a range of [0,255],but it becomes tough for the model to process such high pixel so we need to rescale it before feeding to model.

Model Training :

We are using CNN for training the model,



Model Evaluation:

The model performed very well on the validation as well as on training set . It has able to yield an accuracy of approximately 91% on validation set.

Graph Plot :

Train VS Validation (loss)
Train VS Validation (loss)
Train VS Validation (Accuracy)
Train VS Validation (Accuracy)

Model Prediction :

Link :

Click the below link to access the Notebook .

Credit: Tanmay