Spaces:
Sleeping
Sleeping
Delete README.md
Browse files
README.md
DELETED
|
@@ -1,107 +0,0 @@
|
|
| 1 |
-
# Heart Attack EDA and Detection
|
| 2 |
-
|
| 3 |
-
This project provides a machine learning solution for heart attack detection using Flask and Docker. The system performs exploratory data analysis (EDA) and implements a prediction model for heart attack risk assessment.
|
| 4 |
-
|
| 5 |
-
## Prerequisites
|
| 6 |
-
|
| 7 |
-
### Installing Anaconda/Miniconda
|
| 8 |
-
|
| 9 |
-
1. Download Anaconda or Miniconda:
|
| 10 |
-
- [Anaconda](https://www.anaconda.com/products/distribution)
|
| 11 |
-
- [Miniconda](https://docs.conda.io/en/latest/miniconda.html)
|
| 12 |
-
|
| 13 |
-
2. Follow the installation instructions for your operating system:
|
| 14 |
-
- Windows: Run the installer executable
|
| 15 |
-
- Linux: `bash Anaconda-latest-Linux-x86_64.sh`
|
| 16 |
-
- macOS: `bash Anaconda-latest-MacOSX-x86_64.sh`
|
| 17 |
-
|
| 18 |
-
3. Verify installation:
|
| 19 |
-
```bash
|
| 20 |
-
conda --version
|
| 21 |
-
```
|
| 22 |
-
|
| 23 |
-
### Installing Docker
|
| 24 |
-
|
| 25 |
-
1. Download Docker Desktop:
|
| 26 |
-
- [Docker Desktop](https://www.docker.com/products/docker-desktop)
|
| 27 |
-
|
| 28 |
-
2. Installation by OS:
|
| 29 |
-
- Windows: Run the Docker Desktop Installer
|
| 30 |
-
- macOS: Drag Docker to Applications folder
|
| 31 |
-
- Linux: Follow the [official guide](https://docs.docker.com/engine/install/)
|
| 32 |
-
|
| 33 |
-
3. Verify installation:
|
| 34 |
-
```bash
|
| 35 |
-
docker --version
|
| 36 |
-
```
|
| 37 |
-
|
| 38 |
-
## Project Setup
|
| 39 |
-
|
| 40 |
-
1. Clone the repository:
|
| 41 |
-
```bash
|
| 42 |
-
git clone https://github.com/ahmedhassan456/heart_attack_EDA_and_detection.git
|
| 43 |
-
cd heart_attack_EDA_and_detection
|
| 44 |
-
```
|
| 45 |
-
|
| 46 |
-
2. Create and activate Conda environment:
|
| 47 |
-
```bash
|
| 48 |
-
conda create -n heart_attack_env python=3.10.12
|
| 49 |
-
conda activate heart_attack_env
|
| 50 |
-
```
|
| 51 |
-
|
| 52 |
-
3. Install required packages:
|
| 53 |
-
```bash
|
| 54 |
-
pip install -r requirements.txt
|
| 55 |
-
```
|
| 56 |
-
|
| 57 |
-
## Local Development
|
| 58 |
-
|
| 59 |
-
1. Activate the Conda environment:
|
| 60 |
-
```bash
|
| 61 |
-
conda activate heart_attack_env
|
| 62 |
-
```
|
| 63 |
-
|
| 64 |
-
2. Run the Flask application:
|
| 65 |
-
```bash
|
| 66 |
-
python deployment/app.py
|
| 67 |
-
```
|
| 68 |
-
|
| 69 |
-
3. Access the application at `http://localhost:8000`
|
| 70 |
-
|
| 71 |
-
## Docker Deployment
|
| 72 |
-
|
| 73 |
-
1. Build the Docker image:
|
| 74 |
-
```bash
|
| 75 |
-
docker build -t heart-attack-detection .
|
| 76 |
-
```
|
| 77 |
-
|
| 78 |
-
2. Run the Docker container:
|
| 79 |
-
```bash
|
| 80 |
-
docker run -it -p 8000:8000 heart-attack-detection
|
| 81 |
-
```
|
| 82 |
-
|
| 83 |
-
3. Access the application at `http://127.0.0.1:8000`
|
| 84 |
-
|
| 85 |
-
## Project Structure
|
| 86 |
-
|
| 87 |
-
```
|
| 88 |
-
Heart Attack EDA and Detection/
|
| 89 |
-
βββ deployment # Folder contain the deployment files using Flask
|
| 90 |
-
βββ controller # Floder contain files to load and predict the model
|
| 91 |
-
βββ models/ # Trained model files
|
| 92 |
-
βββ templates/ # HTML templates
|
| 93 |
-
βββ app.py # Flask application
|
| 94 |
-
βββ test_model # Folder contain the notebook and the data
|
| 95 |
-
βββ Dockerfile # Docker configuration
|
| 96 |
-
βββ requirements.txt # Python dependencies
|
| 97 |
-
βββ README.md # Project documentation
|
| 98 |
-
```
|
| 99 |
-
|
| 100 |
-
## API Endpoints
|
| 101 |
-
|
| 102 |
-
- `/`: Home page
|
| 103 |
-
- `/predict`: Endpoint for heart attack prediction
|
| 104 |
-
|
| 105 |
-
## License
|
| 106 |
-
|
| 107 |
-
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|