def _check_image(self, image_nD):
        """Sanity checks on the image data"""

        self.input_image = load_image_from_disk(image_nD)

        if len(self.input_image.shape) < 3:
            raise ValueError('Input image must be atleast 3D')

        if np.count_nonzero(self.input_image) == 0:
            raise ValueError('Input image is completely filled with zeros! '
                             'Must be non-empty')
def _check_image ( self , image_nD ) : self . input_image = load_image_from_disk ( image_nD ) if len ( self . input_image . shape ) < 3 : raise ValueError ( 'Input image must be atleast 3D' ) if np . count_nonzero ( self . input_image ) == 0 : raise ValueError ( 'Input image is completely filled with zeros! ' 'Must be non-empty' )
Sanity checks on the image data