Spaces:
Runtime error
Runtime error
MohamedRashad
commited on
Commit
•
74a2ba9
1
Parent(s):
6dcfe26
Add poppler-utils package and remove unnecessary system commands
Browse files- app.py +0 -4
- packages.txt +1 -0
app.py
CHANGED
@@ -4,10 +4,6 @@ import torch
|
|
4 |
from PIL import Image
|
5 |
from pathlib import Path
|
6 |
from pdf2image import convert_from_path
|
7 |
-
import os
|
8 |
-
|
9 |
-
os.system("apt-get update")
|
10 |
-
os.system("apt-get install poppler-utils")
|
11 |
|
12 |
# Load the model and processor
|
13 |
processor = NougatProcessor.from_pretrained("MohamedRashad/arabic-small-nougat")
|
|
|
4 |
from PIL import Image
|
5 |
from pathlib import Path
|
6 |
from pdf2image import convert_from_path
|
|
|
|
|
|
|
|
|
7 |
|
8 |
# Load the model and processor
|
9 |
processor = NougatProcessor.from_pretrained("MohamedRashad/arabic-small-nougat")
|
packages.txt
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
poppler-utils
|