How to flatten this:
b = np.array([
[[1,2,3], [4,5,6], [7,8,9]],
[[1,1,1],[2,2,2],[3,3,3]]
])
into:
c = np.array([
[1,2,3,4,5,6,7,8,9],
[1,1,1,2,2,2,3,3,3]
])
Niether of these work:
c = np.apply_along_axis(np.ndarray.flatten, 0, b)
c = np.apply_along_axis(np.ndarray.flatten, 0, b)
Just returns the same array.
It would be great to flatten this in place.