Spaces:
Runtime error

victdamn commited on
Commit
cf7efbd
·
verified ·
1 Parent(s): c7ec9aa
Files changed (1) hide show
  1. app.py +7 -2
app.py CHANGED
@@ -19,7 +19,7 @@ with open("annoy_metadata.json", 'r') as f:
19
  metadata = json.load(f)
20
 
21
 
22
- def run(text, input_image, n_pictures):
23
  if not input_image:
24
  return
25
 
@@ -72,6 +72,10 @@ with gr.Blocks(
72
  label="Уточнение изображения на английском (опционально)", placeholder="A photo of a cute dog"
73
  )
74
 
 
 
 
 
75
  # generate
76
  generate_button = gr.Button("Найти", variant='primary')
77
 
@@ -85,7 +89,8 @@ with gr.Blocks(
85
  inputs=[
86
  prompt_input,
87
  image_input,
88
- pictures_slider
 
89
  ],
90
  outputs=gallery
91
  )
 
19
  metadata = json.load(f)
20
 
21
 
22
+ def run(text, input_image, n_pictures, detect_flag):
23
  if not input_image:
24
  return
25
 
 
72
  label="Уточнение изображения на английском (опционально)", placeholder="A photo of a cute dog"
73
  )
74
 
75
+ checkbox = gr.Checkbox(
76
+ False, label="Поиск объекта на картинке"
77
+ )
78
+
79
  # generate
80
  generate_button = gr.Button("Найти", variant='primary')
81
 
 
89
  inputs=[
90
  prompt_input,
91
  image_input,
92
+ pictures_slider,
93
+ checkbox
94
  ],
95
  outputs=gallery
96
  )