Christopher Duym

Back to projects

Client project · Early-stage healthcare startup · 6-person Agile team · Jan–May 2024

Hospital Risk Prediction Web App

A machine learning dashboard that predicts hospital stress levels from simulated operational data.

My role: Designed the MySQL schema and built the background service that polls simulated hospital systems.

  • Python
  • Django REST
  • Scikit-learn
  • MySQL
  • Docker

Developed a Scikit-learn machine learning model to predict hospital stress levels using synthetic data.

Built a Python data generator and a Django REST API that simulate polling hospital systems and persist collected data in MySQL.

Integrated user authentication into a Bootstrap-based dashboard for viewing real-time risk-level predictions.

Collaborated on a six-person Agile team, delivering functional code and documentation to the client in biweekly sprints.

How it works

  1. Simulated hospital systems

    A dummy API in its own Docker container serves staffing and bed-occupancy readings.

  2. Polling service

    Built by me

    An APScheduler background job requests a new reading every 10 seconds and validates it with a Django REST serializer before saving.

  3. MySQL database

    Built by me

    Readings, training data, and predictions live in separate tables; risk predictions and incident logs reference the reading they belong to.

    • hospital_data
    • training_data
    • risk_data
    • incident_log
    • email_recipient
  4. Prediction job

    A Scikit-learn random forest trained on synthetic data scores each new reading and stores the risk level and probability.

  5. Dashboard

    Built by me

    An authenticated Bootstrap dashboard shows the latest risk level. I designed its layout and the prediction display.

Data flows top to bottom. Highlighted steps are the parts I built.