--- a/compute-regions.py Tue Aug 29 17:34:09 2017 +0300 +++ b/compute-regions.py Tue Aug 29 21:01:57 2017 +0300 @@ -3,13 +3,20 @@ from misc import * from geometry import * from zipfile import ZipFile +from configparser import ConfigParser + +representatives = {} + +region_data = ConfigParser() +region_data.read('regions.ini') + +for section in region_data.sections(): + for key, value in region_data[section].items(): + representatives[key] = value with open('regions.gmp') as file: data = file.read().split('@') -with open('region-representatives.json') as file: - representatives = json.load(file) - bus_stops = {} with ZipFile('gtfs.zip') as archive: