ssd-pytorch
ssd-pytorch copied to clipboard
大佬,我在运行get_dr_txt时,出现如下问题。所用的图片尺寸为320*320,您看看该怎么解决?谢谢!
Traceback (most recent call last):
File "C:\ssd-pytorch-master\get_dr_txt.py", line 77, in
File "C:\ssd-pytorch-master\get_dr_txt.py", line 25, in detect_image preds = self.net(photo)
File "C:\Anaconda3\lib\site-packages\torch\nn\modules\module.py", line 532, in call result = self.forward(*input, **kwargs)
File "C:\ssd-pytorch-master\nets\ssd.py", line 69, in forward self.priors
File "C:\ssd-pytorch-master\nets\ssd_layers.py", line 32, in forward self.num_classes).transpose(2, 1)
RuntimeError: shape '[1, 8732, 2]' is invalid for input of size 19180
感觉你这里要么将图片改成300 * 300,要么去处理特征图的大小和计算