-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathget_data.py
executable file
·29 lines (27 loc) · 978 Bytes
/
get_data.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from lib.download_data import download_data
from lib.geocode_addresses import geocode_addresses
from lib.boundaries_for_points import boundaries_for_points
from lib.prep_officer_data import prep_officer_data
from lib.render_json import render_officers_json, render_cases_json
from lib.render_includes import render_includes
if __name__ == '__main__':
print "Downloading data..."
download_data()
print "Prep officer data"
prep_officer_data()
print "Geocoding addresses..."
geocode_addresses()
try:
print "Get boundaries for points..."
boundaries_for_points()
except:
print "ERROR: Unable to get boundaries for points. Is the boundary service running?"
print "Exiting..."
exit()
print "Rendering cases and officer front-end json..."
render_cases_json()
render_officers_json()
print "Rendering case search form include..."
render_includes()