anikde commited on
Commit
916bd05
·
1 Parent(s): 476f8b5

updated for CPU

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -28,7 +28,7 @@ def process_image(image, identifier_lang):
28
  image.save(image_path)
29
 
30
  # Initialize OCR with the selected identifier language
31
- ocr = OCR(identifier_lang=identifier_lang, verbose=False)
32
 
33
  # Detect bounding boxes on the image using OCR
34
  detections = ocr.detect(image_path)
 
28
  image.save(image_path)
29
 
30
  # Initialize OCR with the selected identifier language
31
+ ocr = OCR(device="cpu", identifier_lang=identifier_lang, verbose=False)
32
 
33
  # Detect bounding boxes on the image using OCR
34
  detections = ocr.detect(image_path)