Heramb26 commited on
Commit
2f2995e
·
1 Parent(s): 0218a3d

Chnages to APP

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -11,7 +11,7 @@ checkpoint_folder = hf_hub_download(repo_id="Heramb26/tr-ocr-custom-checkpoints"
11
  device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
12
 
13
  # Load the fine-tuned model and processor from the downloaded folder
14
- model = VisionEncoderDecoderModel.from_pretrained(checkpoint_folder).to(device)
15
  processor = TrOCRProcessor.from_pretrained("microsoft/trocr-large-handwritten")
16
 
17
  def ocr_image(image):
 
11
  device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
12
 
13
  # Load the fine-tuned model and processor from the downloaded folder
14
+ model = VisionEncoderDecoderModel.from_pretrained("Heramb26/tr-ocr-custom-checkpoints/checkpoint-2070").to(device)
15
  processor = TrOCRProcessor.from_pretrained("microsoft/trocr-large-handwritten")
16
 
17
  def ocr_image(image):