Update app.py
Browse files
app.py
CHANGED
@@ -67,11 +67,12 @@ def read_pdf_with_pdfplumber(file):
|
|
67 |
all_page_text=" "
|
68 |
with pdfplumber.open(file) as pdf:
|
69 |
page = pdf.pages[0]
|
70 |
-
|
71 |
-
|
72 |
-
#img = Image.open(im)
|
73 |
-
img = page.save("img.png")
|
74 |
image_name = cv2.imread("img.png")
|
|
|
|
|
|
|
75 |
## get co-ordinates to cr
|
76 |
text = pytesseract.image_to_string(image_name, lang="ben") if st.checkbox("Mark to see Bangla Image's Text") else pytesseract.image_to_string(image_name)
|
77 |
all_page_text += text + " " #page.extractText()
|
|
|
67 |
all_page_text=" "
|
68 |
with pdfplumber.open(file) as pdf:
|
69 |
page = pdf.pages[0]
|
70 |
+
img = Image.open(im)
|
71 |
+
img = img.save("img.png")
|
|
|
|
|
72 |
image_name = cv2.imread("img.png")
|
73 |
+
# get co-ordinates to c
|
74 |
+
#return page.extract_text()
|
75 |
+
# get co-ordinates to cr
|
76 |
## get co-ordinates to cr
|
77 |
text = pytesseract.image_to_string(image_name, lang="ben") if st.checkbox("Mark to see Bangla Image's Text") else pytesseract.image_to_string(image_name)
|
78 |
all_page_text += text + " " #page.extractText()
|