1 from csv import DictReader
2 from datetime import datetime
6 def __init__(self, area = None, stream_file = None):
9 self._stream_file = stream_file
10 self._get_located_interventions()
13 def _get_located_interventions(self):
14 with open(self._stream_file) as f:
15 reader = DictReader(f, delimiter=',')
17 start = datetime.strptime(row['start'], '%d/%m/%Y %H:%M:%S')
19 end = datetime.strptime(row['end'], '%d/%m/%Y %H:%M:%S')