Spaces:
Running
Running
Update Layoutlmv3_inference/ocr.py
Browse files
Layoutlmv3_inference/ocr.py
CHANGED
@@ -92,7 +92,8 @@ def run_tesseract_on_preprocessed_image(preprocessed_image, image_path):
|
|
92 |
url = "https://api.ocr.space/parse/image"
|
93 |
|
94 |
# Define the API key and the language
|
95 |
-
api_key = "K88232854988957" # Replace with your actual OCR Space API key
|
|
|
96 |
language = "eng"
|
97 |
|
98 |
# Save the preprocessed image
|
|
|
92 |
url = "https://api.ocr.space/parse/image"
|
93 |
|
94 |
# Define the API key and the language
|
95 |
+
# api_key = "K88232854988957" # Replace with your actual OCR Space API key
|
96 |
+
api_key = os.getenv("ocr_space")
|
97 |
language = "eng"
|
98 |
|
99 |
# Save the preprocessed image
|