Y.O.D.A RECOGNITION
Your Optical Detection Assistant — AI-powered face recognition and image analysis.
OVERVIEW
Y.O.D.A (Your Optical Detection Assistant) is an advanced facial recognition system engineered to detect, analyze, and verify faces from uploaded images. By seamlessly integrating traditional computer vision techniques, such as Haar Cascades, with modern AI embedding models like CLIP, the application delivers a highly efficient and interactive facial recognition pipeline.
KEY FEATURES
- ▸ Hybrid Architecture: Combines the speed of Haar Cascade face detection with the robust accuracy of CLIP-based AI embeddings.
- ▸ Intelligent Deduplication: Automatically analyzes and compares facial embeddings to maintain a strictly unique dataset.
- ▸ Real-Time Interface: A responsive, Streamlit-powered web application facilitating seamless image ingestion and instant processing.
- ▸ Vector Database: Leverages PostgreSQL and pgvector for highly optimized storage and retrieval of high-dimensional data.
- ▸ Dynamic Configuration: Allows users to adjust core detection parameters and sensitivity thresholds directly through the UI.
SYSTEM ARCHITECTURE
TECHNOLOGIES USED
INSTALLATION & DATABASE SETUP
1. Clone the repository and install dependencies:
git clone https://github.com/AAFLY99/yoda-face-recognition.git cd yoda-face-recognition pip install -r requirements.txt
2. Configure PostgreSQL with pgvector:
conn = psycopg2.connect(
host="localhost",
database="yoda",
user="postgres",
password="your_password"
)
3. Run the application:
streamlit run app.py
DATABASE SCHEMA & DESIGN
The system's backend is anchored by a PostgreSQL database utilizing the pgvector extension. This robust architecture enables the efficient storage of high-dimensional AI embeddings and facilitates low-latency cosine similarity searches for rapid duplicate detection.
- id: SERIAL PRIMARY KEY
- embedding: VECTOR(512) — AI representation
- image_path: VARCHAR(255)
- added_at: TIMESTAMP DEFAULT NOW()
<=>). If the resulting distance is below the predefined threshold, the entry is classified as a duplicate.