Skip to content

This project implements a Siamese Neural Network for efficient image triplet analysis, seamlessly integrating OpenCV for image collection. Three categories of images - positive, negative, and anchor - are collected using OpenCV and preprocessed to standardize dimensions to 100x100 pixels in JPEG format.

Notifications You must be signed in to change notification settings

MOHINI1403/Deep-Facial-Recognisation-System

Repository files navigation

Deep Facial Recognition System

Python OpenCV TensorFlow Anaconda

Description

This project implements a Siamese Neural Network for efficient image triplet analysis, seamlessly integrating OpenCV for image collection. Three categories of images - positive, negative, and anchor - are collected using OpenCV and preprocessed to standardize dimensions to 100x100 pixels in JPEG format.

Flow Chart

Research Paper

Link to Research Paper

Workflow Overview

  1. Data Collection: Utilizing OpenCV, 300 images are collected from each category: positive, negative, and anchor.
  2. Preprocessing: Images are resized to 100x100 pixels and converted to JPEG format.
  3. Dataset Creation: Positive and negative image pairs are combined with anchor images, generating a labeled dataset. Positive pairs are labeled as 1, and negative pairs as 0.
  4. Training Data Preparation: The dataset is split into training and testing sets in a 70-30 ratio and batched with a size of 8 for efficient processing.
  5. Siamese Model Architecture: A Siamese neural network is constructed with an embedding layer for feature extraction and a custom distance layer for similarity computation.
  6. Model Training: The Siamese model is trained on the prepared dataset, optimizing recall and precision metrics for performance evaluation.
  7. Real-Time Verification: OpenCV is employed for real-time image verification, showcasing the practical application of the trained model.

Embedding Layer

Embedding Layer

Siamese Model

Siamese Model

Tech Stack

Python

Tensorflow

Open-CV

Usage

  1. Clone the Repository:

    git clone https://github.com/MOHINI1403/Deep-Facial-Recognisation-System.git
  2. Install Dependencies:

    pip install -r requirements.txt
  3. Folder Structure:

    • Data Folder:
      • Contains three sections: positive, negative, and anchor images.
      • Use OpenCV to collect images for the positive and negative sections.
      • Negative images can be downloaded here.
    • Application Images Folder:
      • Contains two folders: input_image and verification_images.
      • verification_images folder should contain around 50 images randomly selected from positive and anchor sets.
  4. Virtual Environment:

    • Create a virtual environment named faceid:
      python -m venv faceid
    • Activate the virtual environment:
      • On Windows:
        faceid\Scripts\activate
      • On macOS and Linux:
        source faceid/bin/activate

Contribution

Contributions are welcome! Fork the repository, make your changes, and submit a pull request.

Key Components

  • OpenCV Integration: Efficient image collection and real-time verification.
  • Siamese Neural Network: Architecture for learning image similarity through feature embeddings.
  • Custom Distance Layer: Calculates the L1 distance between embeddings for similarity assessment.
  • Training Evaluation: Metrics such as recall and precision used to assess model performance.

Further Assitance :

Try Reading this Documentation :

Link to Documentation

About

This project implements a Siamese Neural Network for efficient image triplet analysis, seamlessly integrating OpenCV for image collection. Three categories of images - positive, negative, and anchor - are collected using OpenCV and preprocessed to standardize dimensions to 100x100 pixels in JPEG format.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages