wai572 commited on
Commit
9169217
·
1 Parent(s): 5a89790
Files changed (1) hide show
  1. main.py +1 -1
main.py CHANGED
@@ -216,7 +216,7 @@ async def analyze_image(image_paths: list[UploadFile]):
216
  # )
217
  img = candidate["img"]
218
  text_mask = get_not_white_mask(img)
219
- masked_img = cv2.bitwise_and(img, img, mask=text)
220
  # result = reader.readtext(candidate["img"])
221
  result = reader.readtext(masked_img)
222
  print(result)
 
216
  # )
217
  img = candidate["img"]
218
  text_mask = get_not_white_mask(img)
219
+ masked_img = cv2.bitwise_and(img, img, mask=text_mask)
220
  # result = reader.readtext(candidate["img"])
221
  result = reader.readtext(masked_img)
222
  print(result)