MCPcopy Create free account
hub / github.com/AtlasAnalyticsLab/AdaFisher / flops

Method flops

Image_Classification/src/models/focalnet.py:368–373  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

366 return x, H, W
367
368 def flops(self):
369 Ho, Wo = self.patches_resolution
370 flops = Ho * Wo * self.embed_dim * self.in_chans * (self.patch_size[0] * self.patch_size[1])
371 if self.norm is not None:
372 flops += Ho * Wo * self.embed_dim
373 return flops
374
375
376class FocalNet(nn.Module):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected