File size: 780 Bytes
ff6071e
9667e74
ff6071e
9667e74
ff6071e
9667e74
 
 
 
 
ff6071e
9667e74
 
 
 
 
 
 
 
 
96ea347
0e28768
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import gradio as gr
from NTED.NTED_module import NTED

NTED_Module = NTED()

def pose_transfer(上传人体姿态图):
    img = 上传人体姿态图
    fake_img = NTED_Module.inference(img)
    
    return fake_img

with gr.Column():
    result_gallery = gr.Gallery(label='Output', show_label=False, elem_id="gallery").style(grid=2, height='auto')

gr.Interface(fn=pose_transfer, 
             inputs=["image"], 
             outputs=[result_gallery],
             title="谷小雨姿态驱动图像",
             examples=[["example/exp1.png"], ["example/exp2.png"], ["example/exp3.png"],\
                 ["example/exp4.png"], ["example/exp5.png"], ["example/exp6.png"]],
             ).launch(share=True)  # (server_name='0.0.0.0')  

'''
TODO
测试视频展示功能
'''