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

Error in trans_conv2d when model is reparametrized #21

Closed
rameshamurtaza opened this issue Mar 3, 2023 · 2 comments
Closed

Error in trans_conv2d when model is reparametrized #21

rameshamurtaza opened this issue Mar 3, 2023 · 2 comments

Comments

@rameshamurtaza
Copy link

conv_transpose2d(): argument 'groups' (position 7) must be int, not tuple

I used this command to convert my model to bnn (const_bnn_prior_parameters) and now getting this error

@Spiffical
Copy link

I believe I found the error. In line 812 of bayesian_torch/layers/variational_layers/conv_variational.py the F.conv_transpose2d function is being called as:

out = F.conv_transpose2d(input, weight, bias, self.stride,
                                 self.padding, self.output_padding,
                                 self.dilation, self.groups)

i.e. the order is dilation then groups, whereas as seen in https://pytorch.org/docs/stable/generated/torch.nn.functional.conv_transpose2d.html , the order should be groups then dilation:

out = F.conv_transpose2d(input, weight, bias, self.stride,
                                 self.padding, self.output_padding,
                                 self.groups, self.dilation)

ranganathkrishnan added a commit that referenced this issue Jan 2, 2024
…se layers.

Fix issue #21

Signed-off-by: Ranganath Krishnan <ranganath.krishnan@intel.com>
@ranganathkrishnan
Copy link
Contributor

Fixed. commit 97ba16a

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

3 participants