AlexHung29629 commited on
Commit
ff8b804
·
verified ·
1 Parent(s): 98be180

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -8,7 +8,7 @@ pipe = pipeline("image-to-text", model="google/pix2struct-screen2words-large")
8
  # Define the function
9
  @spaces.GPU
10
  def describe_ui(image):
11
- outputs = pipe(image)
12
  return outputs[0]['generated_text']
13
 
14
  # Launch the Gradio interface
 
8
  # Define the function
9
  @spaces.GPU
10
  def describe_ui(image):
11
+ outputs = pipe(image=image, text="describe this image.")
12
  return outputs[0]['generated_text']
13
 
14
  # Launch the Gradio interface