PhillyAlert shows neighborhood disruption signals for Philadelphia, detected from aggregate Wi‑Fi access-point churn and cross-referenced with live Philly311 reports.
The Wi‑Fi data is simulated. The routers, their day-to-day churn and the five incidents are generated by pipeline/build_dataset.py to show how detection works. The real parts are the city and neighborhood boundaries and the live 311 reports. The pipeline already accepts real daily observations (see pipeline/README.md).
The map also has an Ida 2021 replay of the September 2021 Schuylkill flood. The river levels, USGS high-water marks, flood extent and 311 reports in it are real; only the routers are reconstructed (see below).
The core observation comes from Surveilling the Masses with Wi‑Fi‑Based Positioning Systems (Rye & Levin, 2024). When a Wi‑Fi access point (AP) loses power or is destroyed, it drops out of Wi‑Fi positioning databases about a week later. After the Maui fire, the APs that vanished from Apple's WPS lined up with the burn map. In Gaza, the share of still-visible APs fell far below a Tel Aviv control group. PhillyAlert turns that idea around for civic use: it watches Philadelphia at the neighborhood level for outages, floods, fires and sudden influxes. It never tracks individual devices.
You need Node 20+ with pnpm, and Python 3 for the data pipeline.
cd webpnpm installpnpm devThen open http://localhost:5173. pnpm build writes a static site to web/dist/; every asset path is relative, so it works from any folder. Pushing to main deploys it to GitHub Pages through .github/workflows/pages.yml. Enable it once under the repo's Settings → Pages → Source: GitHub Actions.
To regenerate the demo data (a simulated 60 days ending today):
python pipeline/build_dataset.pyIt writes web/public/data/wifi_churn.json plus the city and neighborhood boundaries. To rebuild the Ida replay (web/public/data/ida_2021.json), run python pipeline/build_dataset.py --scenario ida-2021. Its real inputs are cached in pipeline/raw/ida_2021/; add --refresh to download them again.
Landing page (#/). The main graphic is the real hex grid on the latest day, with newspaper-style callouts. Below it: three charts of the kinds of signal (an outage and its recovery, a one-block fire, move-in week), the method, and the privacy commitments.
Map (#/map).
| Piece | What it does |
|---|---|
| Map | About 1,700 hexagons (roughly 450 m across) clipped to the city limits. They're colored by how each cell's share of baseline routers still visible compares with the city median: red means more loss than the city, blue means more gain. The CARTO basemap is re-inked to match the site's palette. |
| Alert strip | The most severe active incident you aren't already looking at, with links to zoom in or open PECO's outage map. |
| Sidebar: dataset switch | Demo scenarios (five staged incidents ending today) or Ida flood, 2021. The choice is kept in the URL, e.g. #/map?data=ida-2021. |
| Sidebar: timeline | Scrub or play through the 60-day window. Charts never show data after the selected day. |
| Sidebar: Incidents | A feed of active incidents plus the ones that ended earlier in the window. Opening one shows an area-vs-control chart (the paper's Figure 12 comparison), when it was first flagged, the likely start date after the ~7-day lag, routers dark, live 311 reports in those hexagons, and a copyable text brief. Clicking any hexagon shows the same view for that cell. |
| Sidebar: Map layers | What colors the map (loss, new routers, density), which layers show, including live 311 infrastructure reports, and a jump-to-neighborhood box. |
| Sidebar: Detection | Minimum gap from the city, z-score threshold, and smallest hexagon counted. Loosen them to see the noise floor. |
The demo dataset contains these events, so you can see how each kind of signal looks:
| Scenario | What the signal does |
|---|---|
| Storm outage in Port Richmond / Kensington | Power is restored, so APs come back a week later and the incident resolves. |
| Rowhome fire in Haddington | One cell loses about 14% of its APs for good. |
| Flood outage in Eastwick / Penrose | Active and critical at the end of the window. |
| Main St flooding in Manayunk | Emerging: first flagged 3 days before the end of the window. |
| Semester move-in around Temple (Hartranft / North Central) | A surge of newly seen APs, flagged as a population influx. |
Every scenario includes the ~7-day positioning-database lag the paper measured (§7).
On September 1–2, 2021, the remnants of Hurricane Ida pushed the Schuylkill to 16.35 ft at Fairmount Dam, its highest since 1869. The replay covers Aug 9 – Oct 7, 2021.
| Real | Source |
|---|---|
| River stage, 15-minute readings, and flood stages | USGS gauge 01474500; NWS gauge PADP1 |
| 38 high-water marks surveyed after the flood | USGS Short-Term Network, event 312 |
| Flooded ground: below the water surface interpolated from the marks, connected to the river, not already water, within 450 m of a mark | USGS 3DEP 1 m elevation, OpenStreetMap water, the marks above |
| Which flooded ground has buildings on it | City of Philadelphia L&I building footprints |
| 311 infrastructure reports from those weeks | Philly311 (same API as the live map) |
Reconstructed: the routers. No public Wi‑Fi data from 2021 exists, so the replay uses the demo's synthetic baseline and turns routers off only in flooded buildings. A hexagon's exposure is the share of its buildings under water. Of the routers hit, 35% are back within 1–4 days, 20% stay dark for 1–4 weeks, and 45% are destroyed and replaced 2–7 weeks later. The positioning database drops a router only after 5–9 dark days. So brief outages never show, which is also why the storm's short power cuts elsewhere in the city don't appear. The detector finds Manayunk's Main Street and the riverside buildings by the Chestnut Street bridge, and dates both to about Sep 1.
- Baseline. Each cell's APs present during a baseline week.
- Daily counts per cell. Baseline APs still present (
alive) and cumulative newly seen APs (new). These two integers per cell per day are the only data the site receives. - Control. The baseline-weighted median cell. The paper used a separate region (Tel Aviv); inside one city a median does the same job, and a big outage can't drag it down.
- Flagging a loss. The cell's surviving share is at least X points below the control, the binomial z-score is at or below −z, and at least 8 APs are involved.
- Flagging an influx. The same test on new APs, using a Poisson model.
- Incidents. Adjacent flagged cells are grouped, linked day to day, and kept once they persist for 3 days (or are happening on the latest day).
- Classification. Four or more cells is a widespread outage; fewer is a localized loss (fire, flood, collapse or demolition). An incident is Restored once its cells rejoin the control. Severity comes from the number of APs dark and the share of the area lost.
The detection runs in the browser (web/src/lib/detect.ts), so the sliders re-run it live.
The paper is primarily a warning. The same data that shows Lahaina burning also lets anyone follow a travel router across a border. This project keeps the useful half and designs out the harmful half:
- Aggregate only. No BSSID, SSID or per-AP coordinate reaches the browser. Cells with fewer than 25 baseline APs are suppressed.
- Opt-outs are honored.
_nomap/_optoutSSIDs, and locally administered (randomized or phone-hotspot) MACs, are dropped at ingest. - No linking. BSSIDs are hashed with a per-run random salt that is never saved, so nothing can be linked across runs or used to track movement.
- No scraping. There is intentionally no client for Apple's (or Google's) positioning service here. Mass-querying it is exactly the abuse the paper disclosed, and Apple has since added mitigations. Real deployments should use data you're authorized to collect; see
pipeline/README.md.
web/ React 19 + TypeScript + Vite + Tailwind + shadcn/ui
src/pages/Landing.tsx landing page
src/pages/MapPage.tsx map desk: sidebar feed, detail views, alert strip, legend
src/components/map/MapView.tsx MapLibre wrapper: hex layers, markers, hover, basemap re-inking
src/components/HexMap.tsx static SVG city grid for the landing page
src/components/LineChart.tsx area-vs-control chart with hover and table view
src/lib/detect.ts control series, cell tests, incident tracking
src/lib/phl311.ts live Philly311 query (OpenDataPhilly Carto API)
src/lib/data.ts dataset + 311 loading, shared between pages
public/data/ generated dataset + simplified boundaries
pipeline/build_dataset.py hex grid, simulator, and real-snapshot ingestion
pipeline/ida_2021.py Ida 2021 replay: gauge, high-water marks, flood footprint
pipeline/raw/ida_2021/ cached real inputs for the replay
pipeline/raw/ city limits + neighborhood boundaries (OpenDataPhilly)
- Rye, E. & Levin, D. Surveilling the Masses with Wi‑Fi‑Based Positioning Systems. IEEE S&P 2024 (arXiv:2405.14975).