Skip to content

An elegant macOS demo app built with SwiftUI that leverages CoreML for real-time bone fracture detection from X-ray images. This project demonstrates how deep learning models can be seamlessly integrated into Swift-based apps for medical image analysis and AI-powered diagnostics.

License

Notifications You must be signed in to change notification settings

MianMHaroon/DeepLearning_CoreML_SwiftUI_BoneFractureDetection

Repository files navigation

Bone Fracture Detector — macOS SwiftUI Demo

Bone Fracture Detection


Disclaimer: This project is for educational and research purposes only. It must not be used for real medical diagnosis.


A simple macOS demo app built with SwiftUI using a Core ML image classification model to detect bone fractures from X‑ray images.

I used a publicly available dataset from Kaggle, formatted it for Core ML training, then converted it into .mlmodel format.

Dataset format used for Create ML / Core ML training:

train/
 ├─ shoulderfracture/
 │   └─ images...
 └─ forearmfracture/
     └─ images...

You can train your own model using this same structure. I have also attached the formatted dataset to make training easier.


How to Run the Project

  1. Download or clone this repository.
  2. Open the .xcodeproj file in Xcode.
  3. Press Run to launch the macOS app.

The .mlmodel file is already included, so the app will work immediately.


Core ML Model

  • Dataset taken from Kaggle.
  • Converted into Core ML format.
  • Trained using Create ML with the folder structure shown above.

You may replace the model with your own by training in Create ML and dropping the new .mlmodel file into the Xcode project.


License

MIT License


Author

Muhammad Haroon Email: mianmharoon72@gmail.com LinkedIn: https://www.linkedin.com/in/mian-haroon


References

About

An elegant macOS demo app built with SwiftUI that leverages CoreML for real-time bone fracture detection from X-ray images. This project demonstrates how deep learning models can be seamlessly integrated into Swift-based apps for medical image analysis and AI-powered diagnostics.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages