Baymax is a full-stack digital healthcare platform designed to streamline medical appointments and provide automated AI-driven skin disease screening. By combining a robust Django REST API backend, a modern React frontend, and a PyTorch-based Deep Learning model (ResNet-18), Baymax delivers intelligent doctor recommendations, appointment management, and multimodal skin lesion assessment.
- Role-based authentication system for Patients and Doctors
- Custom onboarding workflows for each user type
- Detailed user profiles:
- Patients: Age, Gender, Medical History
- Doctors: Specialization, Availability Hours, Professional Bio
- JWT Authentication using SimpleJWT
- Secure access and refresh token workflow
- Automatic token management via Axios interceptors
- Enter symptoms in plain text
- Intelligent symptom-to-specialization mapping
- Example recommendations:
- Rash β Dermatologist
- Cough β General Physician
- Chest Pain β Cardiologist
Patients can:
- Select a Doctor
- Choose Appointment Date
- Select Available Time Slot
- Describe Symptoms
Track appointment status:
- Pending
- Confirmed
- Cancelled
Manage and review upcoming consultations easily.
Upload skin lesion images for classification using a fine-tuned ResNet-18 model trained on the HAM10000 Dataset.
Supported disease categories include:
- Actinic Keratoses
- Basal Cell Carcinoma
- Benign Keratosis-like Lesions
- Dermatofibroma
- Melanoma
- Melanocytic Nevi
- Vascular Lesions
The prediction engine combines:
- Uploaded skin lesion image
- Itching
- Pain
- Burning sensation
- Duration
- Lesion location
This fusion improves prediction quality and diagnostic relevance.
The system provides:
- Disease classification
- Confidence score
- Severity level
- Personalized care recommendations
- Triage warnings
- Doctor consultation recommendations for critical cases
| Technology | Purpose |
|---|---|
| Django 5 | Backend Framework |
| Django REST Framework | REST APIs |
| SimpleJWT | Authentication |
| django-cors-headers | Cross-Origin Support |
| SQLite | Database |
| Pillow | Image Processing |
| PyTorch | Model Inference |
| Technology | Purpose |
|---|---|
| React 18 | SPA Development |
| React Router v6 | Routing |
| Tailwind CSS | Styling |
| Axios | API Communication |
| Radix UI | UI Components |
| Lucide React | Icons |
| Technology | Purpose |
|---|---|
| PyTorch 2.0 | Deep Learning |
| torchvision | Image Processing |
| scikit-learn | Data Splitting |
| Pandas | Data Handling |
| NumPy | Numerical Computation |
| TensorBoard | Training Visualization |
baymax/
βββ appointments/
β βββ models.py
β βββ serializers.py
β βββ views.py
β
βββ baby/
β βββ models.py
β βββ serializers.py
β βββ views.py
β
βββ baymax/
β βββ settings.py
β βββ urls.py
β βββ wsgi.py
β
βββ diagnosis/
β βββ views.py
β βββ ml_inference.py
β
βββ frontend/
β βββ public/
β βββ src/
β βββ components/
β βββ Api.js
β βββ App.js
β
βββ ml_training/
β βββ outputs/
β βββ config.py
β βββ train.py
β βββ train_multimodal.py
β βββ inference.py
β βββ QUICKSTART.md
β
βββ db.sqlite3
βββ manage.py
βββ README.md
- Python 3.10+
- Node.js 18+
- npm
python -m venv venv
venv\Scripts\activatepython3 -m venv venv
source venv/bin/activatepip install django djangorestframework djangorestframework-simplejwt django-cors-headers pillow torch torchvision pandas numpy scikit-learn tqdm matplotlib tensorboardpython manage.py migratepython manage.py runserverBackend URL:
http://127.0.0.1:8000/
Navigate to frontend directory:
cd frontendInstall packages:
npm installStart development server:
npm startFrontend URL:
http://localhost:3000/
The diagnosis system requires trained model weights:
resnet18_best.pth
or
resnet18_multimodal_best.pth
stored inside:
ml_training/outputs/
archive/
βββ HAM10000_metadata.csv
βββ processed_images_dataset/
βββ processed_images/
cd ml_training
python train.pypython train_multimodal.py --csv path/to/metadata.csv --image-root path/to/imagespython inference.py --image "path/to/lesion_image.jpg"| Method | Endpoint | Description | Authentication |
|---|---|---|---|
| POST | /api/users/login/ |
Obtain JWT Access & Refresh Tokens | No |
| POST | /api/users/token/refresh/ |
Refresh Access Token | No |
| GET | /api/users/profile/ |
Fetch User Profile | Yes |
| POST | /api/users/register/ |
General Registration | No |
| POST | /api/users/register/patient/ |
Patient Registration | No |
| POST | /api/users/register/doctor/ |
Doctor Registration | No |
| GET | /api/users/doctors/ |
Fetch All Doctors | No |
| GET | /api/users/suggest-doctors/ |
Symptom-Based Recommendations | No |
| GET | /api/appointments/ |
Retrieve Appointments | Yes |
| POST | /api/appointments/ |
Book Appointment | Yes |
| PUT/PATCH | /api/appointments/{id}/ |
Update Appointment | Yes |
| DELETE | /api/appointments/{id}/ |
Cancel Appointment | Yes |
| POST | /api/diagnosis/skin-check/ |
AI Skin Disease Screening | No |
- HAM10000 Skin Lesion Dataset
- Stratified Train / Validation / Test Split (70/15/15)
- ResNet-18 Transfer Learning
- Fine-tuned for 7 skin disease classes
- Class-weighted loss handling
- TensorBoard training monitoring
Combines:
- CNN Image Embeddings
- Patient Clinical Metadata
to generate enhanced disease predictions.
Baymax is intended for educational, research, and demonstration purposes only.
The AI predictions, recommendations, and triage advice generated by the system are not a substitute for professional medical diagnosis, treatment, or clinical judgment.
Always consult a qualified dermatologist or healthcare professional regarding any medical condition or health concern.
Developed using:
- Django REST Framework
- React
- PyTorch
- Tailwind CSS
- JWT Authentication
- HAM10000 Dataset
This project is intended for educational and research purposes.
Feel free to fork, modify, and extend the project for learning and experimentation.
