frendyrachman commited on
Commit
adc70f7
·
verified ·
1 Parent(s): 766c1c8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +0 -3
app.py CHANGED
@@ -53,9 +53,6 @@ def preprocess_image(img):
53
  img = ImageEnhance.Contrast(img).enhance(1.5)
54
  img = ImageEnhance.Sharpness(img).enhance(2.0)
55
 
56
- # Convert to grayscale for better OCR performance
57
- img = img.convert('L')
58
-
59
  # Resize for optimal resolution (maintain aspect ratio)
60
  max_size = (1600, 1600)
61
  img.thumbnail(max_size, Image.LANCZOS)
 
53
  img = ImageEnhance.Contrast(img).enhance(1.5)
54
  img = ImageEnhance.Sharpness(img).enhance(2.0)
55
 
 
 
 
56
  # Resize for optimal resolution (maintain aspect ratio)
57
  max_size = (1600, 1600)
58
  img.thumbnail(max_size, Image.LANCZOS)