Can you instead try the following:
# saving the model
torch.save(model.state_dict(), 'checkpoint_densenet.pth')

and then load it:
# define the model
model = DenseNet() 

# load parameters of the model:
model.load_state_dict(torch.load('checkpoint_densenet.pth'))