Downloads · 30 days
0
lixiangchun/imagenet-swav-resnet50w2
imagenet-swav-resnet50w2 is a machine learning model from lixiangchun. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for tf-keras.
Downloads · 30 days
0
Access
Public
Updated Oct 28, 2022
Repo size
115 MB
Likes
0
Public
Click a slice to open those files.
.pt46.3 MB · 40%
From the Hugging Face model README
import trace_layer2 as models
import torch
x=torch.randn(1, 3, 224, 224)
state_dict = torch.load('swav_imagenet_layer2.pt', map_location='cpu')
model = models.resnet50w2()
model.load_state_dict(state_dict)
model.eval()
feature = model(x)
traced_model = torch.jit.load('traced_swav_imagenet_layer2.pt', map_location='cpu')
traced_model.eval()
feature = traced_model(x)