Spaces:
Running
on
Zero
Running
on
Zero
Create app.py
Browse files
app.py
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
import gradio as gr
|
2 |
+
|
3 |
+
def blend(img1, img2, slider):
|
4 |
+
return img1
|
5 |
+
|
6 |
+
with gr.Blocks() as demo:
|
7 |
+
gr.Markdown("""
|
8 |
+
# Image Blender
|
9 |
+
by [Tony Assi](https://www.tonyassi.com/)
|
10 |
+
""")
|
11 |
+
|
12 |
+
with gr.Row():
|
13 |
+
with gr.Column():
|
14 |
+
img1 = gr.Image(type='filepath')
|
15 |
+
img2 = gr.Image(type='filepath')
|
16 |
+
slider = gr.Slider()
|
17 |
+
btn = gr.Button("Blend")
|
18 |
+
with gr.Column():
|
19 |
+
output = gr.Image()
|
20 |
+
|
21 |
+
|
22 |
+
btn.click(fn=blend, inputs=[img1, img2, slider], outputs=output)
|
23 |
+
|
24 |
+
demo.launch()
|