not-lain commited on
Commit
20a2fe0
β€’
1 Parent(s): 958511f

🌘wπŸŒ–

Browse files
Files changed (2) hide show
  1. app.py +3 -3
  2. cool kid.jpg +0 -0
app.py CHANGED
@@ -45,12 +45,12 @@ slider2 = ImageSlider(label="birefnet", type="pil")
45
  image = gr.Image(label="Upload an image")
46
  text = gr.Textbox(label="Paste an image URL")
47
 
48
- chameleon = Image.open("chameleon.jpg")
49
- cool = Image.open("cool kid.jpg")
50
 
51
  url = "https://hips.hearstapps.com/hmg-prod/images/gettyimages-1229892983-square.jpg"
52
  tab1 = gr.Interface(
53
- fn, inputs=image, outputs=slider1, examples=[[chameleon], [cool]], api_name="image"
54
  )
55
 
56
  tab2 = gr.Interface(fn, inputs=text, outputs=slider2, examples=[url], api_name="text")
 
45
  image = gr.Image(label="Upload an image")
46
  text = gr.Textbox(label="Paste an image URL")
47
 
48
+
49
+ chameleon = load_img("chameleon.jpg", output_type="pil")
50
 
51
  url = "https://hips.hearstapps.com/hmg-prod/images/gettyimages-1229892983-square.jpg"
52
  tab1 = gr.Interface(
53
+ fn, inputs=image, outputs=slider1, examples=[chameleon], api_name="image"
54
  )
55
 
56
  tab2 = gr.Interface(fn, inputs=text, outputs=slider2, examples=[url], api_name="text")
cool kid.jpg DELETED
Binary file (869 kB)