If you recreate a new tensor, you will break the computation graph:
Variable(MSECMBSS,requires_grad=True)
# and
Variable(torch.tensor(MSECMBSS),requires_grad=True)

Also, calling detach() will detach this tensor from the computation graph and Autograd won’t calculate the gradients for any parameters which were used to create this tensor. The same applies to numpy() calls.
Note that Variables are deprecated since 0.4 so you shouldn’t use them anymore.
To keep the computation graph complete, you would have to only use PyTorch methods, without any calls to detach(), numpy(), item(), or recreating tensors.