Spaces:
Sleeping
Sleeping
Upload 2 files
Browse files- README.md +46 -0
- requirements.txt +5 -0
README.md
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
title: "San Jose Crash Data Dashboard"
|
| 3 |
+
emoji: 🚦
|
| 4 |
+
colorFrom: blue
|
| 5 |
+
colorTo: red
|
| 6 |
+
sdk: streamlit
|
| 7 |
+
sdk_version: 1.32.0
|
| 8 |
+
app_file: app.py
|
| 9 |
+
pinned: false
|
| 10 |
+
---
|
| 11 |
+
|
| 12 |
+
# San José Real-Time Crash Data Dashboard
|
| 13 |
+
|
| 14 |
+
This is a real-time data visualization dashboard built with Streamlit using San José's open crash dataset API.
|
| 15 |
+
|
| 16 |
+
## Features
|
| 17 |
+
|
| 18 |
+
- Real-time API integration with San José open data portal
|
| 19 |
+
- Interactive charts: weather, surface condition, speed flag, and more
|
| 20 |
+
- Geospatial crash heatmaps
|
| 21 |
+
- Filters for time range (3m, 6m, 9m, 1y) and council district
|
| 22 |
+
- Toggleable views and "🔁 Refresh Data" button
|
| 23 |
+
|
| 24 |
+
## Setup Instructions
|
| 25 |
+
|
| 26 |
+
1. Clone the repo or upload files to Hugging Face Spaces
|
| 27 |
+
2. Ensure Python 3.8+ environment
|
| 28 |
+
3. Install dependencies:
|
| 29 |
+
|
| 30 |
+
```bash
|
| 31 |
+
pip install -r requirements.txt
|
| 32 |
+
```
|
| 33 |
+
|
| 34 |
+
4. Run the Streamlit app:
|
| 35 |
+
|
| 36 |
+
```bash
|
| 37 |
+
streamlit run app.py
|
| 38 |
+
```
|
| 39 |
+
|
| 40 |
+
## Live Deployment
|
| 41 |
+
|
| 42 |
+
To deploy on [Hugging Face Spaces](https://huggingface.co/spaces), include this README and ensure the file structure matches:
|
| 43 |
+
|
| 44 |
+
- app.py
|
| 45 |
+
- requirements.txt
|
| 46 |
+
- README.md
|
requirements.txt
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
streamlit
|
| 2 |
+
pandas
|
| 3 |
+
requests
|
| 4 |
+
altair
|
| 5 |
+
pydeck
|