I have a 4D array, of which 3D \'slices\' in the first dimension are sometimes all nans. I\'m looking for a pythonic way to prune these. Currently I\'m using a for loop and