  import logging
import h5py
import numpy as np
from skimage import io, filters
from skimage.transform import resize
from skimage.morphology import disk
from skimage.measure import label
from skimage.util import img_as_float
from skimage.color import label2rgb
from skimage.filters import threshold_otsu
from skimage.segmentation import random_walker
from skimage.measure import regionprops
from skimage.morphology import remove_small_objects
from skimage.morphology import closing
from skimage.morphology import square
from skimage.morphology import erosion
from skimage.morphology import dilation
from skimage.morphology import opening
from skimage.morphology import reconstruction
from skimage.morphology import skeletonize
from skimage.morphology import thin
from skimage.morphology import medial_axis
from skimage.morphology import watershed
from skimage.morphology import convex_hull_image
from skimage.morphology import convex_hull_object
from skimage.morphology import convex_hull_points
from skimage.morphology import convex_hull_set
from skimage.morphology import convex_hull_path
from skimage.morphology import convex_hull_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_hull_set_image
from skimage.morphology import convex_hull_set_object
from skimage.morphology import convex_hull_set_points
from skimage.morphology import convex_hull_set_path
from skimage.morphology import convex_hull_set_polygon
from skimage.morphology import convex_h