Skip to content

"RuntimeError: invalid unordered_map<K, T> key" #1

Description

@vegetableclean

Hi, thanks for you paper, it is very exciting.
But, may I have a question, when I tried to implementation your WCC function to replace conv1x1, It occurs this:
"RuntimeError: invalid unordered_map<K, T> key"
Do you have any ides? Thanks!

Here is my code:

class DepthwiseSeparableConv(nn.Module):
def init(self, in_channels, out_channels, kernel_size, stride=1, padding=0, levels=3, compress_rate=0.5, bit_w=4, bit_a=4):
super(DepthwiseSeparableConv, self).init()
self.depthwise = nn.Conv2d(in_channels, in_channels, kernel_size, stride, padding, groups=in_channels, bias=False)
self.pointwise = WCC(in_channels,
out_channels,
1, # stride 為 1
0, # padding 為 0
1, # dilation 為 1
1, # groups 為 1
False, # bias 為 False
levels,
compress_rate,
bit_w,
bit_a
) # 正確地傳遞 wavelet_name 參數

def forward(self, x):
    x = self.depthwise(x)
    x = self.pointwise(x)
    return x

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions