Hi,
I trained a model using an existing code. The model is saved like following during the training:
def model_save(fn):
    with open(fn, 'wb') as f:
        torch.save([model, criterion, optimizer], f)

During inference the original code loads the model like this:
    with open(path, 'rb') as f:
        model = torch.load(f, map_location=lambda storage, loc: storage)

    model.eval()

However since model is saved in a list, model.eval() will threw error.
I used the first element of the list which is supposed to be model itself but I am not sure if the model state_dict() is loaded at all.