Split a 3D numpy array into smaller 3D arrays
问题 I have a 3D np.array arr = np.array([ [ [0, 205, 25], [210, 150, 30], [0, 0, 0], [1, 2, 3], [4, 5, 6], [7, 8, 9] ], [ [0, 255, 0], [255, 40, 0], [0, 0, 200], [7, 8, 9], [10, 11, 12], [120, 51, 58] ], [ [0, 0, 30], [0, 40, 0], [200, 100, 20], [12, 13, 14], [15, 16, 17], [13, 78, 84], ], [ [0, 205, 25], [210, 150, 30], [0, 0, 0], [1, 2, 3], [4, 5, 6], [7, 8, 9] ], [ [0, 255, 0], [255, 40, 0], [0, 0, 200], [7, 8, 9], [10, 11, 12], [120, 51, 58] ], [ [0, 0, 30], [0, 40, 0], [200, 100, 20], [12,