-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
ValueError: operands could not be broadcast together with shapes (441,786,4) (1,1,3) (441,786,4) #599
Comments
I got the same error as you , have you fix it? how can I do next? thanks. |
Make your current path consistent with the path of the pre-trained model.
You can use
>import os
>print(os.path.abspath('.'))
to examine current path
…------------------ 原始邮件 ------------------
发件人: "zhengxinvip"<notifications@github.com>;
发送时间: 2019年7月19日(星期五) 下午3:41
收件人: "jwyang/faster-rcnn.pytorch"<faster-rcnn.pytorch@noreply.github.com>;
抄送: "雨落烂漫"<32668646@qq.com>;"State change"<state_change@noreply.github.com>;
主题: Re: [jwyang/faster-rcnn.pytorch] ValueError: operands could not bebroadcast together with shapes (441,786,4) (1,1,3) (441,786,4) (#599)
I got the same error as you , have you fix it? how can I do next? thanks.
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub, or mute the thread.
|
when I use the voc2007 dataset, there is no problem. but when I use my own dataset, I meet this problem, how did you deal with it, does your error is you don not consistent with the path of the pre-trained model? |
before filtering, there are 8194 images... this is my error. |
I was encountered nearly this (and #616) problem. I changed im = im.astype(np.float32, copy=False)
if im.shape[2] == 4:
# in the event you have an image with alpha channels, drop it for now
im = im[:, :, :3]
im -= pixel_means |
Update: I found above code has another issue. im = im.astype(np.float32, copy=False)
if im.shape[2] == 4:
# in the event you have an image with alpha channels, drop it for now
im = im[:, :, 1:4]
im -= pixel_means |
在$lib\model\util\blob.py的P39行前插入: if im.shape[2] == 4: im = im[:, :, :3] |
Greate job buddy. |
@matonix @peach1995 I have 5 channel and I meet this problem as well. This is my error: ValueError: operands could not be broadcast together with shapes (373,548,5) (1,1,3) (373,548,5). How can I solve this problem. Thank you very much sir. |
No description provided.
The text was updated successfully, but these errors were encountered: