From 28a835204408ea45455f30832c290f2e1640d398 Mon Sep 17 00:00:00 2001 From: thanhvc3 Date: Sat, 27 Apr 2024 10:59:11 +0700 Subject: [PATCH] try swin --- models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/models.py b/models.py index c9cbbea..1c15490 100644 --- a/models.py +++ b/models.py @@ -787,7 +787,7 @@ class WindowAttention(nn.Module): mask: (0/-inf) mask with shape of (num_windows, Wh*Ww, Wh*Ww) or None """ print(x.shape) - B_, N, C, _ = x.shape + B_, C, N, _ = x.shape qkv_bias = None if self.q_bias is not None: qkv_bias = torch.cat((self.q_bias, torch.zeros_like(self.v_bias, requires_grad=False), self.v_bias))