maciejczyzewski / neural-chessboard

♔ An Extremely Efficient Chess-board Detection for Non-trivial Photos ♔
https://arxiv.org/abs/1708.03898
MIT License
286 stars 67 forks source link

H5py OSError: Unable to open file #1

Open RBub opened 6 years ago

RBub commented 6 years ago

Hello, I have installed everything from the master project and when I try to run the train.py I get the following: (turcproj) [Roland@portable-bub test]$ python dataset train data: 10/1529 train data: 20/1529 ... train data: 1510/1529 train data: 1520/1529

(turcproj) [Roland@portable-bub test]$ python train /usr/local/lib/python3.6/importlib/_bootstrap.py:219: RuntimeWarning: compiletime version 3.5 of module 'tensorflow.python.framework.fast_tensor_util' does not match runtime version 3.6 return f(*args, *kwds) ---- FASTEN YOUR SEATBELTS ----- If it's slow, compile protobuf and tensorflow from source! WARNING:tensorflow:From /test/turcproj/lib/python3.6/site-packages/tflearn/initializations.py:119: UniformUnitScaling.init (from tensorflow.python.ops.init_ops) is deprecated and will be removed in a future version. Instructions for updating: Use tf.initializers.variance_scaling instead with distribution=uniform to get equivalent behavior. [FIXME]: only PAMG model is supported 2018-02-26 18:28:38.195309: I tensorflow/core/platform/cpu_feature_guard.cc:137] Your CPU supports instructions that this TensorFlow binary was not compiled to use: SSE4.1 Traceback (most recent call last): File "train", line 77, in read_dataset(NAME), n=int(sys.argv[1])) File "train", line 30, in read_dataset h5f = h5py.File(path, 'r', driver='core') File "/test/turcproj/lib/python3.6/site-packages/h5py/_hl/files.py", line 269, in init fid = make_fid(name, mode, userblock_size, fapl, swmr=swmr) File "/test/turcproj/lib/python3.6/site-packages/h5py/_hl/files.py", line 99, in make_fid fid = h5f.open(name, flags, fapl=fapl) File "h5py/_objects.pyx", line 54, in h5py._objects.with_phil.wrapper File "h5py/_objects.pyx", line 55, in h5py._objects.with_phil.wrapper File "h5py/h5f.pyx", line 78, in h5py.h5f.open OSError: Unable to open file (unable to open file)

(turcproj) [Roland@portable-bub test]$

Any suggestion ?

albertiniufu commented 6 years ago

I have a very similar problem. Any idea on how to fix it?

Using TensorFlow backend. 2018-09-12 14:53:23.123469: I tensorflow/core/platform/cpu_feature_guard.cc:141] Your CPU supports instructions that this TensorFlow binary was not compiled to use: SSE4.1 SSE4.2 AVX AVX2 FMA ---- FASTEN YOUR SEATBELTS ----- If it's slow, compile protobuf and tensorflow from source! [FIXME]: only LAPS model is supported Traceback (most recent call last): File "train.py", line 65, in *read_dataset(NAME), n=int(sys.argv[1])) File "train.py", line 27, in read_dataset h5f = h5py.File(path, 'r', driver='core') File "/home/marcelo/.local/lib/python3.7/site-packages/h5py/_hl/files.py", line 312, in init fid = make_fid(name, mode, userblock_size, fapl, swmr=swmr) File "/home/marcelo/.local/lib/python3.7/site-packages/h5py/_hl/files.py", line 142, in make_fid fid = h5f.open(name, flags, fapl=fapl) File "h5py/_objects.pyx", line 54, in h5py._objects.with_phil.wrapper File "h5py/_objects.pyx", line 55, in h5py._objects.with_phil.wrapper File "h5py/h5f.pyx", line 78, in h5py.h5f.open OSError: Unable to open file (unable to open file)

maciejczyzewski commented 6 years ago

I cannot reproduce this bug. Few ideas:

  1. Update h5py and Python version (>=python3.3)
  2. Remove data/train/laps.h5, data/models/*
  3. Try this combination:
    $ python3 dataset.py
    $ python3 train.py 10
albertiniufu commented 6 years ago

Thanks for your help. Before I had "python-h5py-openmpi 2.8.0-3" and changed to "community/python-h5py 2.8.0-3". Also, I followed your suggestions. python3 dataset.py works The train command still returns the same message.

dan-r95 commented 5 years ago

Ubuntu is case-sensitive, I updated the file name to data/train/LAPS.h5 and now it works.