/stress-level-detector

Detects the stress level of an individual using Machine Learning Algorithms

Primary LanguagePython

Stress Level Detector

home

Problem :

Considering today’s lifestyle, people just sleep forgetting the benefits sleep provides to the human body. Smart-Yoga Pillow (SaYoPillow) is proposed to help in understanding the relationship between stress and sleep and to fully materialize the idea of “Smart-Sleeping” by proposing an edge device. An edge processor with a model analyzing the physiological changes that occur during sleep along with the sleeping habits is proposed. Based on these changes during sleep, stress prediction for the following day is proposed. The secure transfer of the analyzed stress data along with the average physiological changes to the IoT cloud for storage is implemented. A secure transfer of any data from the cloud to any third-party applications is also proposed. A user interface is provided allowing the user to control the data accessibility and visibility. SaYoPillow is novel, with security features as well as consideration of sleeping habits for stress reduction, with an accuracy of up to 96%.

Solution:

This Web app will help you to detects a person's stress level by analysing the values of several features using the Decision Tree Classifier.

Idea:

Building an application that can detect the presence of a mental stress or the possible causes of mental ailments due to stress by indicating the highly relevant factors.

Layout

├───images
├───Tabs
│   └───__pycache__
|   └─── home.py
|   └─── data.py
|   └─── predict.py
|   └─── visualize.py
|   └─── about.py
└───__pycache__
└─── main.py
└─── web_functions.py
└─── requirements.txt
└─── Procfile
└─── setup.sh

Note:

Incase the application demo doesn't start real quick, you can get an idea about how it looks like from the screenshots

image image image image image image

How to run on the project on your local

Table of Contents

Getting Started

These instructions will help you get a copy of the project up and running on your local machine.

Prerequisites

What things you need to install the software and how to install them.

  • Python (version 3.9)
  • seaborn -streamlit
  • numpy
  • matplotlib
  • pandas
  • scikit_learn

Installation

  1. Clone the repository:

    https://github.com/anshumanbehera27/stress-level-detector.git
  2. Navigate to the project directory:

    cd your-repo
  3. Create and activate a virtual environment (optional but recommended):

    python -m venv venv
    source venv/bin/activate  # On Linux/Mac
    # or
    .\venv\Scripts\activate  # On Windows
  4. Install project dependencies:

    pip install -r requirements.txt

    This command installs all the necessary libraries specified in requirements.txt.

  5. Run the code using this command;

    python -m streamlit run app.py