Update ocr.py
Browse files
ocr.py
CHANGED
@@ -7,6 +7,9 @@ Author: Didier Guillevic
|
|
7 |
Date: 2024-11-23
|
8 |
"""
|
9 |
|
|
|
|
|
|
|
10 |
import pytesseract
|
11 |
from pdf2image import convert_from_path
|
12 |
from pdf2image.exceptions import PDFPageCountError, PDFSyntaxError
|
|
|
7 |
Date: 2024-11-23
|
8 |
"""
|
9 |
|
10 |
+
import os
|
11 |
+
os.system("bash setup.sh") # Ensure setup script runs before importing pytesseract
|
12 |
+
|
13 |
import pytesseract
|
14 |
from pdf2image import convert_from_path
|
15 |
from pdf2image.exceptions import PDFPageCountError, PDFSyntaxError
|