rohitashva commited on
Commit
ab68291
·
verified ·
1 Parent(s): 23bf5a5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -5
app.py CHANGED
@@ -13,11 +13,7 @@ from pdf2image import convert_from_path
13
  import torch
14
  import os
15
  # Ensure Poppler is installed
16
- def install_poppler():
17
- if not os.path.exists("/usr/bin/pdftoppm"): # Check if Poppler is installed
18
- st.warning("Installing Poppler for PDF processing...")
19
- subprocess.run(["apt-get", "update"])
20
- subprocess.run(["apt-get", "install", "-y", "poppler-utils"])
21
 
22
  # Load the OCR model
23
  tokenizer = AutoTokenizer.from_pretrained("ucaslcl/GOT-OCR2_0", trust_remote_code=True)
 
13
  import torch
14
  import os
15
  # Ensure Poppler is installed
16
+ poppler_path = "/usr/bin"
 
 
 
 
17
 
18
  # Load the OCR model
19
  tokenizer = AutoTokenizer.from_pretrained("ucaslcl/GOT-OCR2_0", trust_remote_code=True)