MCPcopy Create free account
hub / github.com/HobbitLong/PyContrast / resnet50

Function resnet50

pycontrast/networks/resnet_cmc.py:198–206  ·  view source on GitHub ↗

Constructs a ResNet-50 model. Args: pretrained (bool): If True, returns a model pre-trained on ImageNet

(pretrained=False, **kwargs)

Source from the content-addressed store, hash-verified

196
197
198def resnet50(pretrained=False, **kwargs):
199 """Constructs a ResNet-50 model.
200 Args:
201 pretrained (bool): If True, returns a model pre-trained on ImageNet
202 """
203 model = ResNet(Bottleneck, [3, 4, 6, 3], **kwargs)
204 if pretrained:
205 model.load_state_dict(model_zoo.load_url(model_urls['resnet50']))
206 return model
207
208
209def resnet101(pretrained=False, **kwargs):

Callers

nothing calls this directly

Calls 1

ResNetClass · 0.70

Tested by

no test coverage detected