def edges(input_file, thresh=0.1):
    """Extracts the edges around an ultrasound

  Returns the distance in pixels in the form:
  left,right,top,bottom

  Args:
      input_file: Path to input video (must be mp4, mov, or avi)
      thresh (float, optional): Defaults to 0.1
  """
    import numpy as np
    import cv2
    from pathlib import Path
    from sonocrop import vid
    v, fps, f, height, width = vid.loadvideo(input_file)
    u = vid.countUniquePixelsAlongFrames(v)
    u_avg = u / f
    maxW = np.max(u_avg, axis=0)
    left, right = vid.findEdges(maxW, thresh=thresh)
    maxH = np.max(u_avg, axis=1)
    top, bottom = vid.findEdges(maxH, thresh=thresh)
    return f'{left},{right},{top},{bottom}'
