I have a case where I have input array like this below
array([[[ 1., 0., 2., 0., 3., 0., 4., 0., 5.],
[ 6., 0., 7., 0., 8., 0., 9., 0., 10.],
[11., 0., 12., 0., 13., 0., 14., 0., 15.]],
[[16., 0., 17., 0., 18., 0., 19., 0., 20.],
[21., 0., 22., 0., 23., 0., 24., 0., 25.],
[26., 0., 27., 0., 28., 0., 29., 0., 30.]]])
and I would like to get an output like the one below.
array([[[ 1., 0., 3., 0., 5.],
[ 6., 0., 8., 0., 10.],
[11., 0., 13., 0., 15.]],
[[16., 0., 18., 0., 20.],
[21., 0., 23., 0., 25.],
[26., 0., 28., 0., 30.]]])
I would love if the solution can be generic not just to this example.