holypipette.vision.crop module

Methods to crop images

holypipette.vision.crop.crop_cardinal(image, direction)[source]

Returns a quadrant of the image corresponding to a cardinal point

Parameters:
  • image (the image)

  • direction (cardinal point as a string, in ‘N’, ‘NW’, ‘S’ etc)

holypipette.vision.crop.crop_center(image, ratio=32)[source]

Returns the center of the image.

Parameters:
  • image (the image)

  • ratio (size ratio of cropped image to original image)