ysharma HF Staff commited on
Commit
289ed6d
·
1 Parent(s): 5ed7e5e
Files changed (1) hide show
  1. app.py +10 -0
app.py ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ import gradio as gr
2
+ from PIL import Image
3
+
4
+ demo = gr.Blocks.load(name="spaces/freddyaboulton/blocks_inputs")
5
+ assert demo("Foo", "bar") == "Foo bar"
6
+
7
+ original = Image.open("./cheetah1.jpg")
8
+ output_img_path = demo("./cheetah1.jpg", fn_index=1)
9
+ output = Image.open(output_img_path)
10
+ assert original.size == output.size