ValueError: Cannot feed value of shape (197, 235, 4) for Tensor 'Placeholder:0', which has shape '(?

报错信息如下:

2019-03-13 09:23:04.658024: I c:\users\user\source\repos\tensorflow\tensorflow\core\common_runtime\gpu\gpu_device.cc:1084] Created TensorFlow device (/job:localhost/replica:0/task:0/device:GPU:0 with 6394 MB memory) -> physical GPU (device: 0, name: GeForce GTX 1070, pci bus id: 0000:01:00.0, compute capability: 6.1)
Traceback (most recent call last):
  File "D:/work/SSD-Tensorflow-master/notebooks/ssd_notebook_test.py", line 121, in
    rclasses, rscores, rbboxes = process_image(img)
  File "D:/work/SSD-Tensorflow-master/notebooks/ssd_notebook_test.py", line 86, in process_image
    feed_dict={img_input: img})
  File "C:\Users\11327\AppData\Roaming\Python\Python36\site-packages\tensorflow\python\client\session.py", line 900, in run
    run_metadata_ptr)
  File "C:\Users\11327\AppData\Roaming\Python\Python36\site-packages\tensorflow\python\client\session.py", line 1111, in _run
    str(subfeed_t.get_shape())))
ValueError: Cannot feed value of shape (197, 235, 4) for Tensor 'Placeholder:0', which has shape '(?, ?, 3)'

Process finished with exit code 1

要识别的图片是个污点图片,有错误。是程序生成的图像。能做的就是删除污点图像。
 

你可能感兴趣的:(ValueError: Cannot feed value of shape (197, 235, 4) for Tensor 'Placeholder:0', which has shape '(?)