The following warning is printed when I use register_full_backward_hook and it’s not printed when using register_backward_hook.
I’m using the pretrained SqueezeNet model from torchvision (torchvision.models.squeezenet1_1(pretrained = True))
UserWarning: Output 0 of BackwardHookFunctionBackward is a view and is being modified inplace. 
This view was created inside a custom Function (or because an input was returned as-is) 
and the autograd logic to handle view+inplace would override the custom backward associated 
with the custom Function, leading to incorrect gradients. 
This behavior is deprecated and will be forbidden starting version 1.6. 
You can remove this warning by cloning the output of the custom Function. 
(Triggered internally at  /pytorch/torch/csrc/autograd/variable.cpp:547.)
 result = torch.relu_(input)

This 1 stackoverflow question seems to detail the same problem as well.