xxx1 commited on
Commit
f2977fa
1 Parent(s): 3712cf8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -23,7 +23,7 @@ def caption(input_image):
23
  inputs["num_beams"] = 4
24
  inputs['num_return_sequences'] =4
25
  out = cap_model.generate(**inputs)
26
- return "\n".join(cap_processor.decode(out, skip_special_tokens=True))
27
  import openai
28
  openai.api_key="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"
29
  def gpt3(question,vqa_answer,caption):
 
23
  inputs["num_beams"] = 4
24
  inputs['num_return_sequences'] =4
25
  out = cap_model.generate(**inputs)
26
+ return "\n".join(cap_processor.batch_decode(out, skip_special_tokens=True))
27
  import openai
28
  openai.api_key="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"
29
  def gpt3(question,vqa_answer,caption):