You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I have a basic OCR code in place using easyOCR but I super finicky. It gives like 1 correct result for 10 image captchas which I am trying to solve.
Here is my sample image.
Is there a way to reduce these lines and dots other than text?
Is there a way to improve the quality of image so that the OCR works great?
Here is my code.
from bs4 import BeautifulSoup
import requests
import urllib.request
from pytesseract import image_to_string
import pytesseract
import matplotlib.pyplot as plt
import easyocr
from selenium import webdriver
from selenium.webdriver.support.ui import Select
from selenium.webdriver.support.ui import WebDriverWait
from selenium.common.exceptions import StaleElementReferenceException
from selenium.webdriver.common.keys import Keys
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver.common.by import By
from PIL import Image, ImageEnhance, ImageFilter
import cv2
a2 = plt.imread('screenshots.png')
reader = easyocr.Reader(['en'], gpu=False)
results = reader.readtext(a2)#, allowlist ='0123456789')
print(results)
# # Print the results
for result in results:
numbers=result[1]
print(numbers)
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello, I have a basic OCR code in place using easyOCR but I super finicky. It gives like 1 correct result for 10 image captchas which I am trying to solve.
Here is my sample image.
Here is my code.
Beta Was this translation helpful? Give feedback.
All reactions