diff --git a/src/cleanvision/issue_managers/image_property.py b/src/cleanvision/issue_managers/image_property.py index 328c312d..12f92426 100644 --- a/src/cleanvision/issue_managers/image_property.py +++ b/src/cleanvision/issue_managers/image_property.py @@ -254,7 +254,7 @@ def calculate(self, image: Image) -> Dict[str, Union[float, str]]: ratio = max(image.width, image.height) / self.max_resolution if ratio > 1: resized_image = image.resize( - (int(image.width // ratio), int(image.height // ratio)) + (max(int(image.width // ratio), 1), max(int(image.height // ratio), 1)) ) else: resized_image = image.copy()