@nb.njit
def mine_numba(arr):
    arr2 = np.zeros((arr.size, 3), arr.dtype)
for idx in range(arr.size):
    item = arr[idx]
if item == 1:
    arr2[idx, 2] = 1
elif item == 2:
    arr2[idx, 1] = 1
else:
    arr2[idx, 0] = 1
return arr2
Converting an array of integers to a "vector"