Anusha806 commited on
Commit
c967063
·
1 Parent(s): 02f3d62
Files changed (1) hide show
  1. app.py +15 -7
app.py CHANGED
@@ -329,6 +329,7 @@ def search_by_image(uploaded_image, alpha=0.5, start=0, end=12):
329
  # height="40vh"
330
  # )
331
  import gradio as gr
 
332
  custom_css = """
333
  .search-btn {
334
  width: 100%;
@@ -359,14 +360,21 @@ with gr.Blocks(css=custom_css) as demo:
359
  ["", "Men", "Women", "Boys", "Girls", "Kids", "Unisex"],
360
  label="Gender Filter (optional)"
361
  )
 
 
 
 
 
 
 
362
  with gr.Column(scale=1):
363
- image_input = gr.Image(
364
- type="pil",
365
- label="Upload an image (optional)",
366
- height=256,
367
- width=356
368
- )
369
-
370
 
371
 
372
  search_btn = gr.Button("Search", elem_classes="search-btn")
 
329
  # height="40vh"
330
  # )
331
  import gradio as gr
332
+ import gradio as gr
333
  custom_css = """
334
  .search-btn {
335
  width: 100%;
 
360
  ["", "Men", "Women", "Boys", "Girls", "Kids", "Unisex"],
361
  label="Gender Filter (optional)"
362
  )
363
+ # with gr.Column(scale=1):
364
+ # image_input = gr.Image(
365
+ # type="pil",
366
+ # label="Upload an image (optional)",
367
+ # height=256,
368
+ # width=356
369
+ # )
370
  with gr.Column(scale=1):
371
+ image_input = gr.Image(
372
+ type="pil",
373
+ label="Upload an image (optional)",
374
+ height=256,
375
+ width=356,
376
+ sources=["upload", "clipboard"] # only upload and paste allowed
377
+ )
378
 
379
 
380
  search_btn = gr.Button("Search", elem_classes="search-btn")