Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -13,10 +13,10 @@ from datasets import load_dataset, Image
|
|
13 |
from PIL import Image
|
14 |
from paddleocr import PaddleOCR
|
15 |
from doctr.io import DocumentFile
|
16 |
-
from doctr.models import ocr_predictor
|
17 |
-
|
18 |
|
19 |
|
|
|
|
|
20 |
ocr_model = ocr_predictor(pretrained=True)
|
21 |
|
22 |
|
|
|
13 |
from PIL import Image
|
14 |
from paddleocr import PaddleOCR
|
15 |
from doctr.io import DocumentFile
|
|
|
|
|
16 |
|
17 |
|
18 |
+
os.environ["USE_TORCH"] = "1"
|
19 |
+
from doctr.models import ocr_predictor
|
20 |
ocr_model = ocr_predictor(pretrained=True)
|
21 |
|
22 |
|