Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error running test #4

Open
giacomop96 opened this issue Jul 27, 2020 · 3 comments
Open

Error running test #4

giacomop96 opened this issue Jul 27, 2020 · 3 comments

Comments

@giacomop96
Copy link

Hi, I'm a newbie. I was trying to run train_lenet_decolle.py but i get this error:
C:\Users\gpira\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\decolle-0.1-py3.8.egg\decolle\utils.py:98: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details.
[2, 32, 32]
Traceback (most recent call last):
File "train_lenet_decolle_fa.py", line 39, in
gen_train, gen_test = create_data(chunk_size_train=params['chunk_size_train'],
File "C:\Users\gpira\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\torchneuromorphic\nmnist\nmnist_dataloaders.py", line 170, in create_dataloader
train_d, test_d = create_datasets(
File "C:\Users\gpira\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\torchneuromorphic\nmnist\nmnist_dataloaders.py", line 145, in create_datasets
train_ds = NMNISTDataset(root,train=True,
File "C:\Users\gpira\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\torchneuromorphic\nmnist\nmnist_dataloaders.py", line 63, in init
self.n = f['extra'].attrs['Ntrain']
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 "C:\Users\gpira\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\h5py-2.10.0-py3.8-win-amd64.egg\h5py_hl\attrs.py", line 60, in getitem
attr = h5a.open(self._id, self._e(name))
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\h5a.pyx", line 77, in h5py.h5a.open
KeyError: "Can't open attribute (can't locate attribute: 'Ntrain')"

I am no expert so I can't find the solution, can anyone help me?

@eneftci
Copy link
Member

eneftci commented Aug 3, 2020

Hi Giacomo, I update the decolle library to the latest version. I believe there was a mismatch with torchneuromorphic bit it should be good now. Let me know if you're still having problems.

@giacomop96
Copy link
Author

Hi, I tried again with the new version but I get the same error as before.

@eneftci
Copy link
Member

eneftci commented Aug 4, 2020

Try deleting the created hdf5 files and regenerating them. If you're running the train script without comments, it should be the N-MNIST dataset. Also remember to update torchneuromorphic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants