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
bee9576f03
commit
808f4a7ebd
@ -814,7 +814,7 @@ class MetaFormer(nn.Module):
|
|||||||
#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)
|
||||||
x=self.head(self.norm(x.mean([1, 2])))
|
x=self.head(self.norm(x.mean([2, 3])))
|
||||||
return x
|
return x
|
||||||
|
|
||||||
def forward_features(self, x):
|
def forward_features(self, x):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user