MediPlusPlus commited on
Commit
2ce8c1c
1 Parent(s): 6a68ea7
Files changed (1) hide show
  1. app.py +4 -2
app.py CHANGED
@@ -170,8 +170,10 @@ def m6(que, image):
170
 
171
  # predictions = model3.generate(**inputs)
172
  # return processor3.decode(predictions[0], skip_special_tokens=True)
173
- processor3 = Pix2StructProcessor.from_pretrained('google/matcha-chartqa')
174
- model3 = Pix2StructForConditionalGeneration.from_pretrained('google/matcha-chartqa')
 
 
175
 
176
  inputs = processor3(images=image, text=que, return_tensors="pt")
177
  predictions = model3.generate(**inputs, max_new_tokens=512)
 
170
 
171
  # predictions = model3.generate(**inputs)
172
  # return processor3.decode(predictions[0], skip_special_tokens=True)
173
+
174
+ #match-chartqa used already
175
+ processor3 = Pix2StructProcessor.from_pretrained('google/deplot')
176
+ model3 = Pix2StructForConditionalGeneration.from_pretrained('google/deplot')
177
 
178
  inputs = processor3(images=image, text=que, return_tensors="pt")
179
  predictions = model3.generate(**inputs, max_new_tokens=512)