SEL-Columbia / sequencer

Python library for sequencing the output of Network Planner csv's and shape file outputs
Other
4 stars 4 forks source link

Mysterious input error #53

Closed vr2262 closed 8 years ago

vr2262 commented 8 years ago
$ python mvmax_sequencer.py -i input -o output                                                                                
2016-04-15 13:06:25,590 - sequencer - INFO - sequencer 0.0.5 (Python 2.7.11)
2016-04-15 13:06:25,591 - sequencer - INFO - Asserting Input Projections Match
Traceback (most recent call last):
  File "mvmax_sequencer.py", line 33, in <module>
    nwp = NetworkPlan(shp_file, csv_file, prioritize='Population')
  File "/home/.../Sequencer/sequencer/NetworkPlan.py", line 39, in __init__
    self._assert_proj_match(shp, csv)
  File "/home/.../Sequencer/sequencer/NetworkPlan.py", line 117, in _assert_proj_match
    self.proj = shapefile.crs['proj']
KeyError: 'proj'
vr2262 commented 8 years ago

Also (if it helps), when it fails the value of shapefile.crs is {'init': u'epsg:4326'}.

chrisnatali commented 8 years ago

I think this has to do with a library version incompatibility (gdal or fiona).

Didn't this run without this error on that problematic dataset? If so, what changed?

vr2262 commented 8 years ago

Oh... I think something else I installed into the virtualenv may be the culprit...

vr2262 commented 8 years ago

Yes... When I installed matplotlib it upgraded fiona. You should update Sequencer to use the newest packages!

chrisnatali commented 8 years ago

Cool. Thanks.