Here is what I am currently doing, it works but it's a little cumbersome:
x = np.matrix([[1, 1], [2, -3]])xmax = x.flat[abs(x).argmax()]
Here is what I am currently doing, it works but it's a little cumbersome:
x = np.matrix([[1, 1], [2, -3]])xmax = x.flat[abs(x).argmax()]