mirror of
https://github.com/huggingface/pytorch-image-models.git
synced 2025-06-03 15:01:08 +08:00
Update metaformers.py
This commit is contained in:
parent
cc8575e9d1
commit
3e3010b65e
@ -721,7 +721,7 @@ class MetaFormer(nn.Module):
|
|||||||
if pre_logits:
|
if pre_logits:
|
||||||
return x
|
return x
|
||||||
|
|
||||||
x = x.mean([1,2]) # TODO use adaptive pool instead of mean
|
x = x.mean([-1,-2]) # TODO use adaptive pool instead of mean
|
||||||
x = self.norm(x)
|
x = self.norm(x)
|
||||||
# (B, H, W, C) -> (B, C)
|
# (B, H, W, C) -> (B, C)
|
||||||
x = self.head(x)
|
x = self.head(x)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user