diff --git a/augraphy/augmentations/geometric.py b/augraphy/augmentations/geometric.py index cf1142f..7e5f211 100644 --- a/augraphy/augmentations/geometric.py +++ b/augraphy/augmentations/geometric.py @@ -187,6 +187,7 @@ def run_crop(self, image, mask, keypoints, bounding_boxes): # remove and limit bounding boxes to the cropped boundary if bounding_boxes is not None: # check each point, and remove them if it is outside the cropping area + remove_indices = [] for i, bounding_box in enumerate(bounding_boxes): xspoint, yspoint, xepoint, yepoint = bounding_box # start point is outside the croped area, but end point is inside