MCPcopy Create free account
hub / github.com/TPCD/DCCL / weights_init_classifier

Function weights_init_classifier

model/vision_transformer.py:642–647  ·  view source on GitHub ↗
(m)

Source from the content-addressed store, hash-verified

640
641
642def weights_init_classifier(m):
643 classname = m.__class__.__name__
644 if classname.find('Linear') != -1:
645 nn.init.normal_(m.weight, std=0.001)
646 if m.bias is not None:
647 nn.init.constant_(m.bias, 0.0)
648
649
650class BNClassifier(nn.Module):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected