-
Notifications
You must be signed in to change notification settings - Fork 355
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
when run predict.py #23
Comments
有没有文字描述呀,我看不了这个图 |
TypeError: expected seqence object with len>=0 or a single integer |
TypeError: expected seqence object with len>=0 or a single integer |
我赌五毛版本问题 |
you win |
no I lose |
我遇到同样的问题,请问您怎么解决的,我把torch升级到1.2.0还是不行 |
open-mmlab/mmdetection#2842 |
啊这,是什么东西 |
在rpn.forward里面,roi返回之前先转到cpu上了,从tensor变成了ndarray,所以dataparallel处理不了了,参考https://discuss.pytorch.org/t/nn-dataparallel-typeerror-expected-sequence-object-with-len-0-or-a-single-integer/97082/23
|
啥意思啊,我为什么没听懂…要是哪段代码有问题,我还得改呢,我这里运行没报错,我不知道是啥问题 |
Line 118 in ef53d38
faster-rcnn-pytorch/nets/frcnn.py Line 66 in ef53d38
最后的四个返回值,后两个是ndarray的,不是tensor,按论坛里的说法,Dataparallel多卡分配计算完要合并结果,ndarray合并不了,你在rpn里面把roi放到CPU上了,所以这样。 faster-rcnn-pytorch/nets/rpn.py Line 118 in ef53d38
我怀疑是版本问题,因为你代码里推理的时候把环境变量设置成了1张卡,可能你的版本没问题,别人的版本Dataparallel还是按照多卡的机制gather的,就失败了 |
The text was updated successfully, but these errors were encountered: