Fix unsupported operand Decimal, float

This commit is contained in:
James R. Barlow
2018-11-16 02:13:25 -08:00
parent b183ad8167
commit 2da556bf79

View File

@@ -621,7 +621,7 @@ def select_ocr_image(
# Calculate resolution based on the image size and page dimensions
# without regard whatever resolution is in pageinfo (may differ or
# be None)
bbox = textarea
bbox = [float(v) for v in textarea]
xscale, yscale = float(xres) / 72.0, float(yres) / 72.0
pixcoords = [bbox[0] * xscale,
im.height - bbox[3] * yscale,