This project, Smart Health, uses data mining techniques to predict diseases based on patient symptoms. It employs the Random Forest Classifier as the primary machine learning model and provides a user-friendly interface powered by Streamlit. ๐
- ๐ Overview
- โจ Features
- ๐ Project Structure
- โ๏ธ Setup Instructions
- ๐ Usage
- ๐ ๏ธ Technologies Used
- ๐ Dataset
- ๐ Acknowledgements
Smart Health is a machine learning-based web application designed to assist in diagnosing diseases. It uses a dataset of patient symptoms to train a predictive model and provides insights into the likelihood of various diseases. ๐งฌ
- ๐ High-accuracy predictions using Random Forest.
- ๐ A Streamlit-based interactive and intuitive web application.
- โ Train and save machine learning models with ease.
- ๐ Evaluate model performance on validation and test data.
- ๐ฎ Predict diseases based on symptoms or test datasets.
- ๐ฅ๏ธ User-friendly and interactive UI for non-technical users.
smart_health/
โ
โโโ dataset/
โ โโโ training_data.csv # ๐ Training dataset
โ โโโ test_data.csv # ๐ Test dataset
โ
โโโ saved_model/
โ โโโ random_forest.joblib # ๐ ๏ธ Saved model
โ
โโโ venv/ # ๐ Python virtual environment
โ
โโโ app.py # ๐ฅ๏ธ Streamlit app file
โโโ config.yaml # โ๏ธ Configuration file
โโโ main.py # ๐ง Script for training the model
โโโ test_model.py # ๐ฌ Script for testing the model
โโโ requirements.txt # ๐ฆ Python dependencies
-
Clone the repository:
git clone <repository-url> cd smart_health
-
Create a virtual environment:
python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate
-
Install dependencies:
pip install -r requirements.txt
-
Update the configuration: Edit the
config.yaml
file to specify paths for datasets, saved models, and other parameters. ๐ -
Run the application:
streamlit run app.py
- Specify the model type (e.g., Random Forest) in
main.py
. - Run the script:
The trained model will be saved in the
python main.py
saved_model/
directory. ๐ ๏ธ
Evaluate the model's performance using test_model.py
:
python test_model.py
Launch the app:
streamlit run app.py
Use the web interface to make disease predictions. ๐ฅ๏ธโจ
- Python ๐: Core programming language.
- Streamlit ๐: For building the web interface.
- Scikit-learn ๐: For machine learning models.
- Pandas ๐ผ: For data manipulation.
- PyYAML ๐: For configuration management.
The project uses two datasets:
- training_data.csv: ๐ Dataset for training the model.
- test_data.csv: ๐ Dataset for testing the model.
Each dataset includes:
- ๐ฉบ Patient symptoms (features).
- ๐ฅ Disease prognosis (labels).
- ๐ Scikit-learn Documentation for machine learning references.
- ๐ Streamlit Community for guidance on app development.