[9b0df2]: / README.md

Download this file

91 lines (69 with data), 3.6 kB

Facial Stress Detection using Thermal Imaging

Project Description

  • Accurate detection of mental health diseases is achieved by generating a body heat map of the patient using a thermal camera and applying techniques of image processing and Deep Learning image classification models to measure the disease's magnitude.
  • Working photos/videos here
  • Know more about Problem & Solution here

Dataset

Getting Started

Run:

```bash
$ git clone https://github.com/Sai-Adarsh/facial-stress-using-thermal-image.git

$ cd facial-stress-using-thermal-image

$ pip install -r requirements.txt
```

Open and replace the project path with the respective path inside the below mentioned files:

```bash
project\thermalai\predictor\predict.py

tutorial-2-image-classifier\predict.py

tutorial-2-image-classifier\train.py
```

Activate virtualenv

```bash
# Linux
$ source ./venv/bin/activate

# Windows
$ cd venv/Scripts/

$ activate
```

Train/Test

Place your thermal dataset in the training_data and testing_data folders.

```bash
$ cd tutorial-2-image-classifier

$ python train.py
```

Predict

```bash
$ cd tutorial-2-image-classifier

$ python predict.py sample.jpg (any extension works)
```

Run web app:

```bash
$ cd project\thermalai

$ python manage.py runserver
```

Run through Raspberry Pi (with a camera):

Open a new CMD terminal (Ensure that Raspbian OS is installed on the Raspberry Pi).
```bash
$ cd project\thermalai\thermalai

# Add the desired host and its ports to the ALLOWED_HOSTS section of settings.py
$ cd project\thermalai

$ python manage.py runserver

$ cd RaspberryPi

# Windows
$ runthisstress.sh

# Linux
$ ./runthisstress.sh
```

References