We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fc0b6ad commit 37bbac1Copy full SHA for 37bbac1
timm/models/tnt.py
@@ -488,7 +488,7 @@ def checkpoint_filter_fn(state_dict, model):
488
k = k.replace('outer_attn', 'attn_out')
489
k = k.replace('outer_norm2', 'norm_mlp')
490
k = k.replace('outer_mlp', 'mlp')
491
- if k == 'pixel_pos':
+ if k == 'pixel_pos' and model.pixel_embed.legacy == False:
492
B, N, C = v.shape
493
H = W = int(N ** 0.5)
494
assert H * W == N
0 commit comments