lsa-pucrs / acerta-abide

Deep learning using the ABIDE data
GNU General Public License v2.0
45 stars 25 forks source link

About prepared——Data #6

Closed wyf1995 closed 4 years ago

wyf1995 commented 6 years ago

![Uploading 20180821153238.png…]() when I run the prepared_data.py, I can't solve the problem .Could you help me? Thank you !!!!

problem: Traceback (most recent call last): File "D:/Project/lsa-pucrs-acerta-abide-cc28c56/prepare_data.py", line 128, in hdf5 = hdf5_handler("./data/abide.hdf5", "a") File "D:\Project\lsa-pucrs-acerta-abide-cc28c56\utils.py", line 50, in hdf5_handler with contextlib.closing(h5py.h5f.open(filename, fapl=propfaid)) as fid: 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 65, in h5py.h5f.open TypeError: expected bytes, str found

GordonDoo commented 5 years ago

have you solved this problem

meneguzzi commented 5 years ago

I think we have?

ShekharDewan commented 5 years ago

This still seems to be a problem unfortunately...

Siddharth-Shrivastava7 commented 4 years ago

Convert string mentioned in the argument of 'hdf5_handler' function to bytes by:

hdf5 = hdf5_handler(bytes("./data/abide.hdf5",encoding="utf-8"), 'a' )

It works !

(Python version: 3.7.3 & h5py version: '2.10.0')