earthquake-dashboard / README copy.md
pareshmishra
data
7680d0d

Earthquake AI Detection System (MVP)

Project Structure

  • android_app/: Android (Kotlin) app with sensor detection, AI inference, GPS, and WebView.
  • backend_fastapi/: Python FastAPI server to receive and serve tremor events.
  • web_dashboard/: Streamlit web app for visualization (Hugging Face Spaces compatible).
  • models/: Contains yamnet.tflite and placeholder tremor detection model.

Instructions

  1. Android App

    • Open android_app/ in Android Studio.
    • Replace backend URL in API call.
    • Build and install on Android device.
  2. Backend

    • Navigate to backend_fastapi/
    • Install dependencies: pip install fastapi uvicorn
    • Run with: uvicorn main:app --reload
  3. Web Dashboard

    • Navigate to web_dashboard/
    • Install dependencies: pip install streamlit
    • Run with: streamlit run dashboard.py

Upload everything to your GitHub repo once unzipped.

*** Test data in command line - curl -X POST https://overflowing-intuition-production.up.railway.app/upload
-H "Content-Type: application/json"
-d '[ { "lat": 31.2304, "lon": 121.4737, "label": "mainshock", "timestamp": "2025-07-07T08:45:00" }, { "lat": 35.6762, "lon": 139.6503, "label": "aftershock", "timestamp": "2025-07-07T09:20:00" }, { "lat": 1.3521, "lon": 103.8198, "label": "seismic_event", "timestamp": "2025-07-07T10:05:00" }, { "lat": 21.0278, "lon": 105.8342, "label": "foreshock", "timestamp": "2025-07-07T11:30:00" } ]'

curl -X POST https://overflowing-intuition-production.up.railway.app/upload
-H "Content-Type: application/json"
-d '[ { "lat": -4.769, "lon": 11.866, "label": "mainshock", "timestamp": "2025-07-07T08:00:00" }, { "lat": -5.816, "lon": 13.450, "label": "aftershock", "timestamp": "2025-07-07T08:45:00" }, { "lat": 0.392, "lon": 9.454, "label": "seismic_event", "timestamp": "2025-07-07T09:30:00" }, { "lat": 3.752, "lon": 8.774, "label": "foreshock", "timestamp": "2025-07-07T10:15:00" }, { "lat": -8.838, "lon": 13.234, "label": "tremor", "timestamp": "2025-07-07T11:00:00" }, { "lat": 4.067, "lon": 9.700, "label": "impact", "timestamp": "2025-07-07T11:45:00" } ]'