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

why the createmask function is 49*49? #21

Open
henbucuoshanghai opened this issue Mar 9, 2022 · 1 comment
Open

why the createmask function is 49*49? #21

henbucuoshanghai opened this issue Mar 9, 2022 · 1 comment

Comments

@henbucuoshanghai
Copy link

def create_mask(window_size, displacement, upper_lower, left_right):
mask = torch.zeros(window_size ** 2, window_size ** 2)

it is 49*49 in all tne swin network,why?

@henbucuoshanghai
Copy link
Author

dots[:, :, -nw_w:] += self.upper_lower_mask
dots[:, :, nw_w - 1::nw_w] += self.left_right_mask

why ?56*56**96 the first 3 line to 53,54 55 lines?

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

1 participant