Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -20,7 +20,8 @@ def infer(con_im,ref_im):
|
|
20 |
generated = p2p.transfer_as(condition, reference)
|
21 |
#generated.show()
|
22 |
return generated
|
23 |
-
|
|
|
24 |
|
25 |
with gr.Blocks() as app:
|
26 |
gr.Markdown("<center><h1 style='font-size:xxx-large;'>Pose Transfer Demo</h1><br><h3>repo: <a href='https://github.com/prasunroy/pose-transfer'>https://github.com/prasunroy/pose-transfer</a></h3>")
|
@@ -28,9 +29,11 @@ with gr.Blocks() as app:
|
|
28 |
condition_im = gr.Image(label='Style Image', type='filepath')
|
29 |
reference_im = gr.Image(label='Pose Image', type='filepath')
|
30 |
with gr.Accordion("Pose Maker",open=False):
|
|
|
31 |
pose_maker=gr.HTML("<iframe src='https://omnibus-model-mover.hf.space' width='100%' height='520'></iframe>")
|
32 |
btn=gr.Button()
|
33 |
|
34 |
output_im = gr.Image()
|
|
|
35 |
btn.click(infer,[condition_im,reference_im], output_im)
|
36 |
app.launch()
|
|
|
20 |
generated = p2p.transfer_as(condition, reference)
|
21 |
#generated.show()
|
22 |
return generated
|
23 |
+
def transf(inp):
|
24 |
+
return inp
|
25 |
|
26 |
with gr.Blocks() as app:
|
27 |
gr.Markdown("<center><h1 style='font-size:xxx-large;'>Pose Transfer Demo</h1><br><h3>repo: <a href='https://github.com/prasunroy/pose-transfer'>https://github.com/prasunroy/pose-transfer</a></h3>")
|
|
|
29 |
condition_im = gr.Image(label='Style Image', type='filepath')
|
30 |
reference_im = gr.Image(label='Pose Image', type='filepath')
|
31 |
with gr.Accordion("Pose Maker",open=False):
|
32 |
+
trans_box=gr.Textbox("Transfer Generated Pose Image File> HERE")
|
33 |
pose_maker=gr.HTML("<iframe src='https://omnibus-model-mover.hf.space' width='100%' height='520'></iframe>")
|
34 |
btn=gr.Button()
|
35 |
|
36 |
output_im = gr.Image()
|
37 |
+
trans_box.change(transf,trans_box,reference_im)
|
38 |
btn.click(infer,[condition_im,reference_im], output_im)
|
39 |
app.launch()
|