kh-CHEUNG commited on
Commit
7bfd7cf
·
verified ·
1 Parent(s): 43b044b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -35,7 +35,7 @@ question = "Question answering. Is is a scene of Lifting Operation?"
35
  if testButton and selected_file != "None":
36
  st.write("Testing the model with the selected image...")
37
  # encoding = processor(image, question, words, boxes=boxes, return_tensors="pt")
38
- model_encoding = processor(iamges=image, text=question, return_tensors="pt")
39
  model_output = model.generate(**model_encoding)
40
  output_text = processor.batch_decode(model_output, skip_special_tokens=True)[0]
41
  st.write(output_text)
 
35
  if testButton and selected_file != "None":
36
  st.write("Testing the model with the selected image...")
37
  # encoding = processor(image, question, words, boxes=boxes, return_tensors="pt")
38
+ model_encoding = processor(images=image, text=question, return_tensors="pt")
39
  model_output = model.generate(**model_encoding)
40
  output_text = processor.batch_decode(model_output, skip_special_tokens=True)[0]
41
  st.write(output_text)