I've got 2 long numpy arrays, both having 508 elements. I would like to get the indices of where they differ. Most of the solutions I've seen determining difference here sort the arrays which is not suitable in my case.
Example
arr_1 = [0, 1, 4, 0, 2, 2, 0, 3, 5, ... , 5, 5, 6]
arr_1 = [0, 1, 0, 0, 0, 2, 0, 3, 0, ... , 5, 0, 6]
Hopefully returning something like:
solut = [0, 0, 1, 0, 1, 0, 0, 0, 1, ... , 0, 1, 0]
or even
solut = [2, 4, 8, ..., n-2]
Is there an efficient way to do this in numpy?