We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 71571e3 commit d9e4e4dCopy full SHA for d9e4e4d
modules/masking.py
@@ -49,7 +49,7 @@ def expand_crop_region(crop_region, processing_width, processing_height, image_w
49
ratio_processing = processing_width / processing_height
50
51
if ratio_crop_region > ratio_processing:
52
- desired_height = (x2 - x1) * ratio_processing
+ desired_height = (x2 - x1) / ratio_processing
53
desired_height_diff = int(desired_height - (y2-y1))
54
y1 -= desired_height_diff//2
55
y2 += desired_height_diff - desired_height_diff//2
0 commit comments