CardioVision is a medical screening web application with a Flask backend and a static HTML/CSS/JavaScript frontend. It includes symptom scoring, cardiac risk calculation, ECG/X-ray prediction modules, AI chat support, and medical image preprocessing utilities.
Note: This project is for learning and prototype use. It is not a replacement for professional medical diagnosis.
BIO-PROJECT/
|-- backend/
| |-- App.py
| |-- ai_chat.py
| |-- predict_ecg.py
| |-- predict_xray.py
| |-- risk_engine.py
| |-- symptom_scorer.py
| `-- requirements.txt
|-- frontend/
| |-- index.html
| |-- diagnosis.html
| |-- results.html
| |-- script.js
| `-- style.css
|-- preprocessing/
| |-- __init__.py
| `-- preprocess.py
|-- models/
|-- data/
`-- README.md
- Flask API backend
- Static frontend served by Flask
- Symptom-based scoring
- Cardiac risk calculation
- ECG and X-ray prediction modules
- Medical image preprocessing with OpenCV
.envsupport for local configuration
- Python 3.10+
- Anaconda Prompt or PowerShell
- pip
git clone <your-repository-url>
cd BIO-PROJECTIf you are starting from an empty cloned repository and adding this project:
git add .
git commit -m "Initial CardioVision project"
git branch -M main
git push -u origin mainOpen Anaconda Prompt inside the project folder:
cd D:\BIO-PROJECTCreate and activate an environment:
conda create -n cardiovision python=3.10 -y
conda activate cardiovisionInstall dependencies:
pip install -r backend/requirements.txtIf OpenCV is not available, install it manually:
pip install opencv-pythonCreate a .env file in the project root for local secrets/configuration.
Example:
PORT=5000
FLASK_DEBUG=trueDo not upload .env to GitHub.
Run this command from the project root:
python -c "from preprocessing.preprocess import apply_medical_preprocessing; print('Preprocessing import works!')"From the project root:
python backend/App.pyThen open:
http://localhost:5000
If you are using the included virtual environment on Windows:
.\venv\Scripts\python.exe backend\App.pyInstall packages:
pip install -r backend/requirements.txtRun backend:
python backend/App.pyCheck preprocessing:
python -c "from preprocessing.preprocess import apply_medical_preprocessing; print('Preprocessing import works!')"Check git status:
git statusAdd and commit changes:
git add .
git commit -m "Update project files"Push to GitHub:
git push- Keep
.env, virtual environments, temporary files, datasets, and trained model files out of GitHub unless you intentionally want to publish them. - Store large datasets and trained weights externally, then document download instructions.
- Use
opencv-pythonfor local Anaconda development. Useopencv-python-headlessfor server deployments when GUI support is not needed.