I have an array created by using
array1 = np.array([[25, 160, 154, 233],
[61, 244, 198, 248],
[227, 226, 141, 72 ]
You can set the print options for numpy to do this.
import numpy as np
np.set_printoptions(formatter={'int':hex})
np.array([1,2,3,4,5])
gives
array([0x1L, 0x2L, 0x3L, 0x4L, 0x5L])
The L at the end is just because I am on a 64-bit platform and it is sending longs to the formatter. To fix this you can use
np.set_printoptions(formatter={'int':lambda x:hex(int(x))})