If I have two numpy arrays like:
a = np.array([[ 0, 1, 2, 3],
[ 4, 5, 6, 7],
[ 8, 9, 10, 11]])
b = np.array([ 0, 4, 8])
and I would like to get the index of the column of a that corresponds to the values of b. Here it would be 0.
With something like:
np.where(np.hsplit(a, 4) == b)
I'm able to find the solution but I think it should be some more intuitive way of doing so.