ifire commited on
Commit
d4c9e6c
1 Parent(s): f7b2fb1

Add examples.

Browse files
Files changed (1) hide show
  1. app.py +7 -1
app.py CHANGED
@@ -261,12 +261,18 @@ textbox = gr.inputs.Textbox(placeholder='An apartment with two bedrooms and one
261
  generated = gr.outputs.Image(label='Generated Layout', type='numpy')
262
  layout = gr.outputs.Textbox(label='Layout Coordinates')
263
 
 
 
 
 
 
264
  iface = gr.Interface(fn=prompt_to_layout, inputs=[textbox, creative_slider],
265
  outputs=[generated, layout],
266
  css=custom_css,
267
  theme="default",
268
  allow_flagging='never',
269
  allow_screenshot=False,
270
- thumbnail="thumbnail_gradio.PNG")
 
271
 
272
  iface.launch(enable_queue=True, share=True)
 
261
  generated = gr.outputs.Image(label='Generated Layout', type='numpy')
262
  layout = gr.outputs.Textbox(label='Layout Coordinates')
263
 
264
+ examples = [
265
+ ["two bedrooms and two bathrooms", "Low"],
266
+ ["three bedrooms with a kitchen adjacent to the dining room", "Medium"]
267
+ ]
268
+
269
  iface = gr.Interface(fn=prompt_to_layout, inputs=[textbox, creative_slider],
270
  outputs=[generated, layout],
271
  css=custom_css,
272
  theme="default",
273
  allow_flagging='never',
274
  allow_screenshot=False,
275
+ thumbnail="thumbnail_gradio.PNG",
276
+ examples=examples)
277
 
278
  iface.launch(enable_queue=True, share=True)