Return a length-2 tensor [i_min, i_max] holding the indices (not values) of the minimum and maximum elements of 1-D tensor x.
[i_min, i_max]
x
Input
tensor([5., 1., 9., 3.])
Output
tensor([1, 2])
This one's part of Premium. Unlock the full PyTorch track plus every other premium problem on the site.
solve(...)