适用于pytorch的网络模型ResNet的模型权重
resnet101-5d3b4d8f.pth
resnet152-b121ed2d.pth
resnet18-5c106cde.pth
resnet34-333f7ec4.pth
resnet50-19c8e357.pth
resnext101_32x8d-8ba56ff5.pth
resnext50_32x4d-7cdf4587.pth
调用方法:
model = models.resnet50(pretrained=False)
model.load_state_dict(torch.load('weight/resnet50/resnet50-19c8e357.pth'))
model.fc = nn.Linear(model.fc.in_features, CLASS_NUM)
pretrained表示不下载权重,若用于图片分类,可以在后面加多一层,用来输出CLASS_NUM个结果,即CLASS_NUM个类别
2021-08-13 14:12:36
989.14MB
pytorch