lsc-cnn
lsc-cnn copied to clipboard
Asking for author's help:train error
when i train the lsc-cnn such error happens:
Traceback (most recent call last): File "/home/Linux-doc1/Yxp/lsc-cnn-master/data_reader.py", line 725, in _test_one_image predicted_maps_full_size UnboundLocalError: local variable 'predicted_maps_full_size' referenced before assignment
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/Linux-doc1/Yxp/lsc-cnn-master/main.py", line 1113, in
File "/home/Linux-doc1/Yxp/lsc-cnn-master/main.py", line 657, in test_lsccnn
for e_idx, e_iter in enumerate(e):
File "/home/Linux-doc1/Yxp/lsc-cnn-master/data_reader.py", line 281, in iterate_over_test_data
pred_maps_full_size = self._test_one_image(crops, test_function)
File "/home/Linux-doc1/Yxp/lsc-cnn-master/data_reader.py", line 727, in _test_one_image
predicted_maps_full_size = [np.zeros((pmap.shape[1], crops[6].shape[0], crops[6].shape[1])) for pmap in results]
File "/home/Linux-doc1/Yxp/lsc-cnn-master/data_reader.py", line 727, in
I do not make changes to the original code ,when I start to train or test ,this error always happens, I really want to know the reason why such bug would happen , please!
@knightyxp +1
It could be an issue with the version of Python. When I switched to Python 3.6, the problem was resolved.