update app
Browse files- vietocr/translate.py +1 -1
vietocr/translate.py
CHANGED
@@ -49,7 +49,7 @@ def process_image(image, image_height, image_min_width, image_max_width):
|
|
49 |
w, h = img.size
|
50 |
new_w, image_height = resize(w, h, image_height, image_min_width, image_max_width)
|
51 |
|
52 |
-
img = img.resize((new_w, image_height), Image.
|
53 |
|
54 |
img = np.asarray(img).transpose(2,0, 1)
|
55 |
img = img/255
|
|
|
49 |
w, h = img.size
|
50 |
new_w, image_height = resize(w, h, image_height, image_min_width, image_max_width)
|
51 |
|
52 |
+
img = img.resize((new_w, image_height), Image.Resampling.LANCZOS)
|
53 |
|
54 |
img = np.asarray(img).transpose(2,0, 1)
|
55 |
img = img/255
|