torch.unique with dim: NumPy compatible sorting (#101693)
Fixes https://github.com/pytorch/pytorch/issues/101681. The change `transpose -> moveaxis` was sufficient.
Not only does it make the output similar to NumPy, it also preserves lexicographical sorting order along selected dimensions.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/101693
Approved by: https://github.com/ngimel