💡 Inspiration
Heart disease can affect different people in different ways, and understanding the risk often involves looking at several clinical parameters together. We wanted to explore how machine learning could help make sense of this data and present the results in a way that is easier to understand.
That led us to Cardio3D. Instead of displaying only a risk score, we wanted to connect the prediction to a 3D visualization of the heart, so users could explore potential blockages and understand how they might affect blood flow.
🫀 What It Does
Cardio3D is a prototype that combines machine learning, hemodynamic calculations, and 3D visualization to explore coronary artery disease.
- Risk prediction: Uses clinical parameters to estimate the likelihood of coronary artery disease and potential involvement of the LAD, LCX, and RCA arteries.
- 3D visualization: Displays a 3D heart model with coronary vessels and highlights areas associated with potential blockages.
- Blood flow simulation: Uses a simplified mathematical model to estimate pressure drops across narrowed vessels and calculate an indicative FFR value.
- Virtual stenting: Lets users simulate a stent intervention and observe how changing the vessel dimensions affects the calculated blood flow parameters.
- Model explainability: Uses SHAP to show which input features contribute to an individual prediction.
- Report generation: Generates a PDF summary of the inputs, predictions, and calculated results.
Cardio3D is currently a prototype for exploration and demonstration, not a tool for diagnosing patients or recommending treatment.
🛠️ How We Built It
We divided the project into three main parts: machine learning, hemodynamic calculations, and the interactive interface.
Machine learning: We used the Z-Alizadeh Sani dataset, which contains clinical information from 303 patients. We explored classification models such as XGBoost and Random Forest to predict coronary artery disease risk. SHAP was included to help explain the model's predictions.
Hemodynamic calculations: We implemented a simplified model to estimate the pressure drop across a narrowed vessel. The estimated pressure values are then used to calculate an indicative FFR value. We connected these calculations to the virtual stenting feature to demonstrate how changing the assumed vessel dimensions affects the results.
3D interface: We used React, Three.js, and WebGL to build an interactive heart visualization. The interface includes patient input controls, visual indicators for the coronary arteries, an animated ECG display, and a virtual stenting interaction.
FastAPI connects the interface to the prediction and calculation components.
⚡ Challenges We Ran Into
One of our main challenges was connecting the machine learning predictions to the 3D visualization. A predicted risk score does not directly tell us the actual location or severity of a blockage, so we had to define assumptions for how the results would be represented visually.
Another challenge was making the hemodynamic calculations respond to changes in the simulated vessel dimensions. We also had to keep the 3D visualization and other interface elements responsive while updating the displayed results.
Finally, we worked on making the generated PDF report readable and ensuring that the important information could fit onto a single page.
🏆 Accomplishments That We're Proud Of
We're proud of bringing several different concepts together in one working prototype. Cardio3D combines clinical data, machine learning predictions, mathematical calculations, and interactive 3D visualization instead of presenting them as separate features.
We also built a virtual stenting interaction, integrated SHAP-based explanations, and added PDF report generation. These features helped us explore how complex technical results could be presented through a more interactive interface.
📚 What We Learned
This project helped us understand that building a machine learning model is only one part of a larger system. Connecting its predictions to a meaningful visualization requires additional assumptions and careful consideration of what the model can actually tell us.
We also learned more about using SHAP to interpret predictions, applying mathematical models to simulate blood flow, and connecting a Python backend to a 3D web interface.
Most importantly, we learned the importance of distinguishing between a simulated result and a clinically validated result, especially when working on healthcare-related projects.
🚀 What's Next for Cardio3D
Our next step is to improve how the system represents coronary artery narrowing and validates its calculations. We would also like to explore using medical imaging data, such as coronary CT angiography, to build more realistic patient-specific vessel models.
Other planned improvements include more detailed simulations of stent placement, better evaluation of the prediction models, and tracking changes in patient data over time.
These improvements would help us understand what is needed to move Cardio3D from a demonstration prototype towards a more realistic research tool.
Log in or sign up for Devpost to join the conversation.