Skip to content
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

TypeError: conv2d() received an invalid combination of arguments #80

Open
Zzz730 opened this issue May 5, 2022 · 6 comments
Open

TypeError: conv2d() received an invalid combination of arguments #80

Zzz730 opened this issue May 5, 2022 · 6 comments

Comments

@Zzz730
Copy link

Zzz730 commented May 5, 2022

Hello.Sorry for troubling you. When I run python train_meta.pycfg/metayolo.data cfg/darknet_dynamic.cfg cfg/reweighting_net.cfg darknet19_448.conv.23,a TypeError occured:
TypeError: conv2d() received an invalid combination of arguments - got (Tensor, Parameter, NoneType, tuple, tuple, tuple, int), but expected one of:

  • (Tensor input, Tensor weight, Tensor bias, tuple of ints stride, tuple of ints padding, tuple of ints dilation, int groups)
    didn't match because some of the arguments have invalid types: (Tensor, !Parameter!, !NoneType!, !tuple!, !tuple!, !tuple!, int)
  • (Tensor input, Tensor weight, Tensor bias, tuple of ints stride, str padding, tuple of ints dilation, int groups)
    didn't match because some of the arguments have invalid types: (Tensor, !Parameter!, !NoneType!, !tuple!, !tuple!, !tuple!, int)
@ataftaf
Copy link

ataftaf commented Jun 9, 2022

Hello,
Did you manage to fix it? I am facing the same problem :(
Thanks,

@gusdhg
Copy link

gusdhg commented Jun 10, 2022

Hello,I met the same problem,did you fix it?

@mmtmmt2
Copy link

mmtmmt2 commented Aug 18, 2022

hello,i also met the problem

@zhanjunyao
Copy link

hello, the same problem, how to solve?

@HeuristicLU
Copy link

change darknet_meta.py
226
to: pad = (kernel_size-1)//2 if is_pad else 0
This will work successfully.

@GgJbMy0320
Copy link

I changed pad=(kernel_size-1)/2 to pad=int((kernel_size-1)/2) if is_pad else 0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants