Hi Thomas (and Bin)!



 tom:

this is something where the O(n log n) complexity of sort vs. the O(n) complexity of index assignment shows for large operands.


This is absolutely correct – using argsort() to invert a permutation
has the sub-optimal O(n log n) complexity, and will definitely matter with
large permutations.
Best.
K. Frank