Skip to content

show historical data on dte outages

Notifications You must be signed in to change notification settings

mtfurlan/dte-outage-history

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dte outage

Attempt to show DTE outages over time

DTE runs an arcgis server for it's outage information. I've been scraping it for a while.

I would like to be able to answer questions like

  • how often power goes out at a given location
  • average outage duration for a given location
  • what the worst/best places are for some defintion of best/worst

Data

I didn't realize that the geojson was paginated till recently.

  • 2021-11-08T15:36:27 to 2023-02-26T18:10:09: Truncated sometimes to 1k events.
  • 2023-02-26T18:11:20 and onwards stored as geojson.tgz

If you want any of this data, please let me know (email in commits, or an issue, or whatever)

next steps

  • figure out how to re-assemble the geojson exports into postgis
  • Actually do analysis

What is actually in this repo

scrape

This is the script I have running in a cronjob

There is also fetch.sh in the root of the repo to download data from my server This should really be cleaned up but in the meantime I don't want to lose the script

everything else

THere is a docker-compose.yml to orchistrate all this

  • db: postgis db, with a script to import a single geojson data file
  • api: expose the db
  • web: call the api to get the geojson, and put the outage information on an interactive map

Running

docker-compose up
docker exec -it dte-outage-history_postgres_1 /bin/bash -c "cd /data && ./try.sh"

go to http://localhost:8088

Notes on DTE data

arcgis REST URL

https://outagemap.serv.dteenergy.com/GISRest/services/OMP/OutageLocations/MapServer/

Legend data:

Layers: