From 23c6f849d6026f7e70534ce0e273a458b1da8324 Mon Sep 17 00:00:00 2001 From: jonaswinkler <17569239+jonaswinkler@users.noreply.github.com> Date: Wed, 18 Aug 2021 18:33:33 +0200 Subject: [PATCH] fix bug with DPI calculation --- src/paperless_tesseract/parsers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/paperless_tesseract/parsers.py b/src/paperless_tesseract/parsers.py index 57cfb0118..d53879542 100644 --- a/src/paperless_tesseract/parsers.py +++ b/src/paperless_tesseract/parsers.py @@ -70,7 +70,7 @@ class RasterisedDocumentParser(DocumentParser): try: with Image.open(image) as im: x, y = im.info['dpi'] - return x + return round(x) except Exception as e: self.log( 'warning',