AI-Powered Curbside Intelligence Platform
ParkMesh is an advanced parking spot detection system built for the Google Gemini Hackathon 2026. It leverages Google's Gemini 3.0 Flash model to analyze dashcam footage and identify available parking spots along city streets in real-time.
-
π€ AI-Powered Detection: Uses Gemini 3.0's advanced spatial reasoning to analyze video footage and distinguish between:
- Valid parking spots
- Occupied spaces
- Bus lanes and no-parking zones
- Illegal parking areas
-
π Geospatial Integration: Automatically interpolates GPS coordinates for every detected parking spot based on route telemetry
-
π¨ Interactive Dashboard: Premium Vue 3 web interface featuring:
- Synchronized video playback
- Google Maps visualization
- Real-time spot detection overlay
- Modern, responsive design
ParkMesh uses Gemini 3.0 Flash for comprehensive video analysis:
- Video optimization and preprocessing (FFmpeg downsampling to 3 FPS)
- GPS telemetry interpolation across the entire route
- Frame extraction at detected spot timestamps
- Structured JSON output with GPS coordinates, confidence scores, and metadata
ParkMesh/
βββ analyze_with_gemini.py # Gemini AI analysis script
βββ server.py # FastAPI backend server
βββ gemini_prompt.md # Structured prompt for Gemini
βββ requirements.txt # Python dependencies
βββ .env # API keys (DO NOT commit)
βββ frontend/ # Vue 3 web application
β βββ src/
β βββ package.json
β βββ vite.config.js
βββ uploads/ # Uploaded video files
βββ results/ # Analysis results and frames
Before running ParkMesh, ensure you have the following installed:
- Python 3.10+ with pip
- Node.js 18+ with npm
- FFmpeg (for video processing)
- Conda (recommended for environment management)
- Google Gemini API Key (Get one here)
- Google Maps API Key (Get one here)
git clone <repository-url>
cd ParkMeshUsing Conda (Recommended):
# Create and activate conda environment
conda create -n parkmesh python=3.10
conda activate parkmesh
# Install Python dependencies
pip install -r requirements.txt
pip install fastapi uvicornCreate or update the .env file in the project root:
# .env file
GEMINI_API_KEY=your_gemini_api_key_here
GOOGLE_MAPS_API_KEY=your_google_maps_api_key_herecd frontend
# Install dependencies
npm install
# Create frontend .env file
echo "VITE_GOOGLE_MAPS_API_KEY=your_google_maps_api_key_here" > .envThis runs the complete stack with the premium web interface.
Terminal 1 - Start Backend Server:
conda activate parkmesh
python server.pyThe server will start at http://localhost:8000
Terminal 2 - Start Frontend:
cd frontend
npm run devThe frontend will start at http://localhost:5173
Using the Application:
- Open
http://localhost:5173in your browser - Click on the map to select your starting location
- Upload a dashcam video (MP4/MOV format)
- Click "Start Analysis" and wait for Gemini to process
- View detected parking spots on the interactive map
- Click on spots to see exact frames and details
Analyze a video directly using Gemini AI (without the web interface):
conda activate parkmesh
python analyze_with_gemini.py \
--video path/to/your/video.mp4 \
--start_gps "40.7128,-74.0060" \
--end_gps "40.7138,-74.0050" \
--model gemini-3-flash-preview \
--fps 3Parameters:
--video: Path to dashcam video file--start_gps: Starting GPS coordinates (lat,lon)--end_gps: Ending GPS coordinates (lat,lon)--model: Gemini model to use (default: gemini-3-flash-preview)--fps: Target FPS for optimization (default: 3)--no-optimize: Skip video optimization (faster but uses more tokens)
Output:
analysis_<video_name>.json: Detailed results with spots and GPSprocessed_<video_name>.mp4: Optimized videoframe_<video_name>_<N>.jpg: Extracted frames for each spot
When running server.py, the following endpoints are available:
POST /upload- Upload video for analysis- Form data:
video(file),start_gps(string) - Returns:
{"task_id": "uuid"}
- Form data:
GET /status/{task_id}- Check analysis status- Returns: status, progress, or results
GET /presets/list- List available preset videosPOST /process-preset- Process a preset videoGET /presets/thumbnail/{video_id}- Get video thumbnail
/uploads/*- Uploaded videos/results/*- Analysis results and frames
-
Video Preprocessing:
- FFmpeg downsamples video to 3 FPS
- Reduces file size and API token usage
- Maintains quality for detection
-
GPS Telemetry Generation:
- Interpolates GPS coordinates across video duration
- Creates synchronized location log
-
Gemini Processing:
- Uploads optimized video + telemetry
- Uses structured prompt from
gemini_prompt.md - Gemini analyzes spatial layout and parking regulations
-
Post-Processing:
- Extracts frames at detected spot timestamps
- Generates JSON with GPS coordinates, timestamps, and confidence scores
In analyze_with_gemini.py:
--model: Gemini model to use (default:gemini-3-flash-preview)--fps: Target FPS for video optimization (default: 3)--no-optimize: Skip video optimization to preserve original quality
In server.py:
UPLOAD_DIR: Directory for uploaded videos (default:uploads/)RESULTS_DIR: Directory for analysis results (default:results/)
"GEMINI_API_KEY not found"
- Ensure
.envfile exists in project root - Check API key is valid
"Could not open video source"
- Verify video file path is correct
- Check video codec is supported (H.264 recommended)
Frontend can't connect to backend
- Ensure server is running on port 8000
- Check CORS settings in
server.py
FFmpeg not found
- Install FFmpeg:
sudo apt install ffmpeg(Linux) orbrew install ffmpeg(Mac)
GEMINI_API_KEY=<your_gemini_api_key>
GOOGLE_MAPS_API_KEY=<your_maps_api_key>
VITE_GOOGLE_MAPS_API_KEY=<your_maps_api_key>
Backend:
- Python 3.10+
- FastAPI (Web server)
- Google Gemini 3.0 Flash (AI analysis)
- FFmpeg (Video optimization)
Frontend:
- Vue 3 (Framework)
- Vite (Build tool)
- Google Maps JavaScript API
- Modern CSS with animations
This project was created for the Google Gemini Hackathon 2026.
The "Mesh" in ParkMesh represents our vision for a hyper-connected, live urban grid. Our next milestone is a direct integration with cloud-connected dashcams, allowing us to ingest live video streams in real-time. By leveraging the low-latency inference of Gemini 3.0 Flash, we aim to extract and broadcast parking availability within seconds of a camera scanning a street. This real-time feedback loop will turn every connected vehicle into a live sensor, creating a self-healing, instant map of city parking that updates as fast as traffic moves.
Built with β€οΈ for the Google Gemini Hackathon 2026