Solved by soulitzer in post #2 
              
              
                The two backward functions behave differently when you try an input where multiple indices are tied for maximum. SelectBackward routes the gradient to the first maximum value while MaxBackward evenly distributes. 
x = torch.tensor([1., 1.], requires_grad=True)
print(torch.autograd.grad(torch.max(x),…