Commit Graph

2 Commits

Author SHA1 Message Date
Hung Luu a7595603b4 Add adaptive det_size, benchmark UI, and code simplification
- Add adaptive det_size selection based on image characteristics
  (portraits use 640, landscapes use 1024)
- Add FaceServiceError for better error handling in face detection
- Add benchmark UI for comparing faces between two images
- Extract face_area() helper to eliminate duplicate sorting logic
- Modernize type hints (List -> list, Tuple -> tuple)
- Add processed_width/height to embed responses
- Add embedding dimension validation

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-05 10:49:50 +07:00
Hung Luu d34b27ecc5 Initial commit: Face embedding service with modular structure
- FastAPI-based face embedding service using InsightFace
- Modular package structure (app/config, app/models, app/face, app/image, app/routes)
- Async HTTP downloads with retry logic (httpx + tenacity)
- Image size/dimension limits and decompression bomb protection
- Comprehensive image decoding with color mode handling
- BBox coordinate clamping and embedding validation
- Production-ready structure with TODOs for security features
2025-12-01 11:38:50 +07:00