We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I saved weight file as below.
import torch from torchvision import models
// Download and load the pre-trained model model = models.densenet121(pretrained=True) print(model)
// Set upgrading the gradients to False for param in model.parameters(): param.requires_grad = False
modelname = 'densenet121.pt' example_input = torch.rand(1, 3, 224, 224) script_module = torch.jit.trace(model, example_input) script_module.save(modelname)
and then,
DenseNet model; std::cout << model << std::endl; model.apply(init_weights); torch::load(model, "densenet121.pt"); <= void load(Value& value, LoadFromArgs&&... args) { ... archive >> value; } unhandled exception happened ㅠㅠ
Thank you in advance for your future help^^
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I saved weight file as below.
import torch
from torchvision import models
// Download and load the pre-trained model
model = models.densenet121(pretrained=True)
print(model)
// Set upgrading the gradients to False
for param in model.parameters():
param.requires_grad = False
modelname = 'densenet121.pt'
example_input = torch.rand(1, 3, 224, 224)
script_module = torch.jit.trace(model, example_input)
script_module.save(modelname)
and then,
DenseNet model;
std::cout << model << std::endl;
model.apply(init_weights);
torch::load(model, "densenet121.pt"); <= void load(Value& value, LoadFromArgs&&... args) { ... archive >> value; } unhandled exception happened ㅠㅠ
Thank you in advance for your future help^^
The text was updated successfully, but these errors were encountered: