Skip to content

samyoga/BioAuth-with-LSH

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

49 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BioAuth-with-LSH

This project implements a secure face recognition system using SimHash a variant of Locality Sensitive Hashing (LSH). The architecture is designed to preprocess face images, generate hashed templates using SimHash, calculate similarity scores using Hamming distance, and evaluate system performance with visualizations like ROC curves and histograms.


Table of Contents


Project Architecture

The project is modularized into the following components:

  1. Classes: Contains classes for essential operations:
    • zip_extractor.py: Extracts zip files.
    • feature_extractor.py: Extracts features of face images.
    • random_vector_generator.py: Generates random vectors.
    • hasher.py: Implements SimHash for hashing.
    • similarity_calculator.py: Calculates similarity using Hamming distance.
    • score_matrix_generator.py: Generates the score matrix.
    • visualizer.py: Generates histograms and ROC curves for evaluation.
  2. Dataset: Contains datasets as zip files.
  3. Files: Stores files generated during preprocessing, hashing, and score matrix generation.
  4. Output: Contains the ROC curve and histogram generated during evaluation.
  5. Old: Contains legacy files for previous SimHash implementations.
  6. main.py: Main function that integrates and executes the pipeline.
  7. README.md: Project documentation.
  8. .gitignore: Specifies files to be ignored by Git.

Installation

  1. Install Python:

    • Ensure Python 3.8 or above is installed on your system. You can download it here.
  2. Clone the Repository:

    git clone https://github.com/your-username/BioAuth-with-LSH.git
    cd BioAuth-with-LSH
    
  3. Set up a virtual environment:

    python -m venv venv
    source venv/bin/activate  # On Windows: venv\Scripts\activate
    
  4. Install dependencies:

    pip install -r requirements.txt
    

Steps

  1. Ensure Python is installed on your system.
  2. Prepare Dataset: Create a folder Dataset and place your dataset as zip files under the Dataset/ folder.
  3. Run the main script:
    python main.py
  4. Access the outputs:
    • Processed files in Files/.
    • Visualizations in Output/.

Contributing

Contributions are welcome! To contribute:

  • Fork this repository.
  • Create a branch for your feature:
    git checkout -b feature-name
    
  • Commit and push your changes:
    git commit -m "Add feature description"
    git push origin feature-name
  • Open a pull request.

License

This project is licensed under the MIT License.

Contact

For questions or feedback, reach out to Samyoga Bhattarai at [[email protected]].

About

Project to secure face recognition system using Locality Sensitive Hashing (LSH)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages