Skip to content
This repository has been archived by the owner on Jun 25, 2024. It is now read-only.

ValueError: output of generator should be a tuple (x, y, sample_weight) or (x, y). Found: None #127

Open
AniketGurav opened this issue Jan 6, 2018 · 2 comments

Comments

@AniketGurav
Copy link

AniketGurav commented Jan 6, 2018

I have installed all packages as per instruction given on main page. But When run this code I get following error

I tensorflow/core/common_runtime/gpu/gpu_device.cc:975] Creating TensorFlow device (/gpu:0) -> (device: 0, name: GeForce GTX 1080 Ti, pci bus id: 0000:02:00.0)

/home/aniket/PycharmProjects/myVirtual3/local/lib/python2.7/site-packages/tensorflow/python/ops/gradients_impl.py:91: UserWarning: Converting sparse IndexedSlices to a dense Tensor of unknown shape. This may consume a large amount of memory.
"Converting sparse IndexedSlices to a dense Tensor of unknown shape.
Exception in thread Thread-1:
Traceback (most recent call last):
File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner
self.run()
File "/usr/lib/python2.7/threading.py", line 754, in run
self.__target(*self.__args, **self.__kwargs)
File "/home/aniket/PycharmProjects/myVirtual3/local/lib/python2.7/site-packages/keras/engine/training.py", line 429, in data_generator_task
generator_output = next(self._generator)
File "SSD_training.py", line 235, in generate
y = self.bbox_util.assign_boxes(y)
File "/home/aniket/PycharmProjects/myVirtual3/ssd_keras-master/ssd_utils.py", line 149, in assign_boxes
assignment[:, 5:-8][best_iou_mask] = boxes[best_iou_idx, 4:]
ValueError: shape mismatch: value array of shape (20,20) could not be broadcast to indexing result of shape (20,3)

Epoch 1/5
Traceback (most recent call last):
File "SSD_training.py", line 315, in
nb_worker=1)
File "/home/aniket/PycharmProjects/myVirtual3/local/lib/python2.7/site-packages/keras/engine/training.py", line 1532, in fit_generator
str(generator_output))
ValueError: output of generator should be a tuple (x, y, sample_weight) or (x, y). Found: None

Please note this issue is not same as #61

@AniketGurav AniketGurav changed the title I have installed all packages as per instruction given on main page. I have installed all packages as per instruction given on main page. But When run this code I get following error Jan 6, 2018
@AniketGurav AniketGurav changed the title I have installed all packages as per instruction given on main page. But When run this code I get following error ValueError: output of generator should be a tuple (x, y, sample_weight) or (x, y). Found: None Jan 6, 2018
@JunSun666
Copy link

I have the same problem. What's the solution?

@atharva-ak
Copy link

Did you get the solution? Please let me know @AniketGurav. Thanks!

# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants