wow, thanks so much! I don't know how you figured that it's HTML, but that's awesome!
Mike On Wed, Oct 25, 2017 at 5:20 AM, Peter Otten <__pete...@web.de> wrote: > C W wrote: > > > Oh, I was running a debug file, that's why the path is different. > > > > The file is here, > > https://www.dropbox.com/s/6jx4rzyg9xwl95m/train_catvnoncat.h5?dl=0 > > > > Is anyone able to get it working? Thank you! > > Hm, that file seems to contain HTML and that causes an OSError here, too: > > $ head -n3 datasets/train_catvnoncat.h5 > > <!DOCTYPE HTML> > <html> > > $ python3 > Python 3.4.3 (default, Nov 17 2016, 01:08:31) > [GCC 4.8.4] on linux > Type "help", "copyright", "credits" or "license" for more information. > >>> import h5py > >>> train_dataset = h5py.File('datasets/train_catvnoncat.h5', "r") > Traceback (most recent call last): > File "<stdin>", line 1, in <module> > File "/usr/lib/python3/dist-packages/h5py/_hl/files.py", line 207, in > __init__ > fid = make_fid(name, mode, userblock_size, fapl) > File "/usr/lib/python3/dist-packages/h5py/_hl/files.py", line 79, in > make_fid > fid = h5f.open(name, h5f.ACC_RDONLY, fapl=fapl) > File "h5f.pyx", line 71, in h5py.h5f.open (h5py/h5f.c:1806) > OSError: unable to open file (File accessibilty: Unable to open file) > > It's not exactly what you see, but that may be due to differing software > versions. > When I replace the HTML file with its namesake found at > > https://github.com/lalxyy/NEU-MCM-Training-4/blob/master/cod > e/datasets/train_catvnoncat.h5 > > I can open it: > > $ file datasets/train_catvnoncat.h5 > datasets/train_catvnoncat.h5: Hierarchical Data Format (version 5) data > > $ python3 > Python 3.4.3 (default, Nov 17 2016, 01:08:31) > [GCC 4.8.4] on linux > Type "help", "copyright", "credits" or "license" for more information. > >>> import h5py > >>> train_dataset = h5py.File('datasets/train_catvnoncat.h5', "r") > >>> > > -- > https://mail.python.org/mailman/listinfo/python-list > -- https://mail.python.org/mailman/listinfo/python-list