CoolFace
Apppublic

sumedhakini/predicting_blood_group_using_fingerprints

sourceHugging Faceupdated 1y agoView on Hugging Face
1likes
App README

๐Ÿง  Prediction of Blood Group Using Fingerprints

This web application uses deep learning models (VGG16 & MobileNetV2) to predict a person's blood group based on a fingerprint image.

Built using Gradio, the app provides an interactive and user-friendly interface for quick predictions.


๐Ÿš€ Features

  • โ€”๐Ÿ” Predicts one of 8 blood groups: A+, A-, B+, B-, AB+, AB-, O+, O-
  • โ€”๐Ÿ“Š Uses two different models to ensure accuracy and compare predictions
  • โ€”๐Ÿ’ก Shows confidence scores and agreement status between models
  • โ€”๐ŸŒ Fully accessible through Hugging Face Spaces โ€” no installation required
  • โ€”๐Ÿ–ผ Includes a sample dataset to try the app easily

๐Ÿง  Models Used

ModelArchitectureInput Size
VGG16Convolutional224x224
MobileNetV2Lightweight CNN224x224

Both models were trained using TensorFlow and saved as .h5 files. Each model independently predicts the blood group based on the fingerprint image.


๐Ÿ—‚ Sample Dataset

A folder named sample_dataset is included in this Space, containing example fingerprint images for each blood group.

Each subfolder corresponds to a blood type:

sample_dataset/ โ”œโ”€โ”€ A+/ โ”œโ”€โ”€ A-/ โ”œโ”€โ”€ B+/ โ”œโ”€โ”€ B-/ โ”œโ”€โ”€ AB+/ โ”œโ”€โ”€ AB-/ โ”œโ”€โ”€ O+/ โ””โ”€โ”€ O-/

You can try out the app by uploading any image from this dataset!


๐Ÿ–ผ Sample Usage

  1. 1.Upload a fingerprint image (JPG/PNG)
  2. 2.The app preprocesses the image automatically
  3. 3.Both models make predictions
  4. 4.You receive:
  5. 5.Predicted blood group from both models
  6. 6.Their confidence scores
  7. 7.Whether the models agree or disagree

๐Ÿ“ File Structure

predicting-blood-group-using-fingerprints โ”‚ โ”œโ”€โ”€ app.py # Gradio app logic โ”œโ”€โ”€ VGG16.h5 # Trained VGG16 model โ”œโ”€โ”€ MobileNetV2.h5 # Trained MobileNetV2 model โ”œโ”€โ”€ requirements.txt # Project dependencies โ”œโ”€โ”€ sample_dataset/ # Example fingerprint images โ”‚ โ””โ”€โ”€ [A+, A-, ..., O-]/ # One folder per blood group โ”œโ”€โ”€ README.md # Project overview (this file) โ””โ”€โ”€ .gitattributes # Git LFS tracking (auto-created)


๐Ÿ›  Run Locally (Optional)

To run this app on your own machine:

1. Clone the repo:

bash
git clone https://huggingface.co/spaces/your-username/predicting-blood-group-using-fingerprints
cd predicting-blood-group-using-fingerprints

### 2. Install Dependencies:
pip install -r requirements.txt

### 3. Launch App:
python app.py

Then visit: http://127.0.0.1:7860

---

Feel free to customize the README as needed.