dhlab-epfl / dhSegment

Generic framework for historical document processing
https://dhlab-epfl.github.com/dhSegment
GNU General Public License v3.0
373 stars 116 forks source link

Can't run train.py #28

Closed alix-tz closed 5 years ago

alix-tz commented 5 years ago

Hello,

I am trying to train my own model with dhSegment but it seems I can't get train.py to run.
I also tried following the demo instructions to see if I was still getting the same error and I do:

python train.py with demo/demo_config.json
Traceback (most recent call last):
  File "train.py", line 8, in <module>
    from dh_segment.io import input
  File "/home/timeus/demo_dhseg/dhSegment/dh_segment/io/__init__.py", line 140, in <module>
    from . import via
  File "/home/timeus/demo_dhseg/dhSegment/dh_segment/io/via.py", line 12, in <module>
    from skimage import transform
  File "/home/timeus/miniconda3/envs/dh_segment/lib/python3.6/site-packages/skimage/__init__.py", line 158, in <module>
    from .util.dtype import *
  File "/home/timeus/miniconda3/envs/dh_segment/lib/python3.6/site-packages/skimage/util/__init__.py", line 7, in <module>
    from .arraycrop import crop
  File "/home/timeus/miniconda3/envs/dh_segment/lib/python3.6/site-packages/skimage/util/arraycrop.py", line 8, in <module>
    from numpy.lib.arraypad import _validate_lengths
ImportError: cannot import name '_validate_lengths'

Is it a problem within the script or am I missing a requirement? For information, I am only using a CPU at the moment.

Many thanks,

alix-tz commented 5 years ago

Fixed this problem :

https://github.com/scikit-image/scikit-image/issues/3586