MCPcopy Create free account
hub / github.com/pytorch/executorch / ResNet50Model

Class ResNet50Model

examples/models/resnet/model.py:36–48  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

34
35
36class ResNet50Model(EagerModelBase):
37 def __init__(self):
38 pass
39
40 def get_eager_model(self) -> torch.nn.Module:
41 logging.info("Loading torchvision resnet50 model")
42 resnet50_model = resnet50(weights=ResNet50_Weights.IMAGENET1K_V1)
43 logging.info("Loaded torchvision resnet50 model")
44 return resnet50_model
45
46 def get_example_inputs(self):
47 input_shape = (1, 3, 224, 224)
48 return (torch.randn(input_shape),)

Callers 3

test_resnet50_fp16Method · 0.90
resnet50.pyFile · 0.90
__init__Method · 0.90

Calls

no outgoing calls

Tested by 1

test_resnet50_fp16Method · 0.72