After calling loss.backward() you could check all gradients by accessing the .grad attribute of all parameters via:
loss.backward()
for name, param in model.named_parameters():
    print(name, param.grad)

Alternatively, you could also calculate specific gradients via e.g. torch.autograd.grad.