Upload everyone's trip photos to one group. DeepFace detects and recognizes real faces, automatically sorting photos by person. Firebase handles real-time cross-device sync.
┌─────────────────┐ ┌──────────────────┐ ┌──────────────┐
│ React Frontend │────▶│ Flask Backend │────▶│ DeepFace │
│ (Vite + React) │ │ (Python API) │ │ (AI Engine) │
└────────┬────────┘ └──────────────────┘ └──────────────┘
│
▼
┌─────────────────┐
│ Firebase │
│ Realtime DB │
│ (Group Sync) │
└─────────────────┘
- Go to Firebase Console
- Create a new project (name it anything)
- Go to Build → Realtime Database → Create Database
- Choose Start in test mode
- Go to Project Settings → General → Your apps → Web app
- Click "Add app" → Register → Copy the config object
- Paste config into
frontend/src/firebase.js
cd backend
# Create a virtual environment (REQUIRED on macOS/Linux)
python3 -m venv venv
# Activate it
# macOS / Linux:
source venv/bin/activate
# Windows:
# venv\Scripts\activate
# Install dependencies (inside venv, no errors)
pip install -r requirements.txt
# Run the server (first run downloads ~500MB of AI models)
python app.pyBackend runs on http://localhost:5000
Troubleshooting:
- If you see
externally-managed-environmenterror → you forgot to activate the venv- If
pip installis slow → DeepFace pulls TensorFlow (~400MB), be patient- If you get OpenCV errors on Mac →
brew install opencvthen retry- To deactivate venv when done:
deactivate
cd frontend
npm install
npm run devFrontend runs on http://localhost:5173
# In a new terminal, test if backend is working:
curl http://localhost:5001/api/health
# Should return: {"engine":"DeepFace","status":"ok"}- Create Group → Get a 6-digit invite code
- Share Code → Friends join from any device
- Upload Photos → Sent to Flask backend → DeepFace detects faces
- Face Matching → DeepFace.verify() compares face pairs
- Auto-Sort → Photos grouped by person, synced via Firebase
- Download → Get your photos or everyone's
cd backend
# Set environment variable:
export FLASK_ENV=production
gunicorn app:app --bind 0.0.0.0:5000cd frontend
# Update VITE_API_URL in .env to your backend URL
npm run build
# Deploy dist/ to Vercel- DeepFace — Face detection (RetinaFace) + verification (VGG-Face)
- Firebase Realtime DB — Cross-device group sync
- Flask + Flask-CORS — Python API backend
- React + Vite — Frontend