File size: 495 Bytes
d4757ae
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
27
from typing import Callable
import gradio as gr
import numpy as np


examples = [
    [
        #"data_video_sun_5s.mp4",
        "data_video_sun.mp4",
        "data_audio_sun_5s.wav",
    ],
]


def make_demo(fn: Callable):
    demo = gr.Interface(
        fn=fn,
        inputs=[
            gr.Video(label="Face video"),
            gr.Audio(label="Audio", type="filepath"),
        ],
        outputs="video",
        examples=examples,
        allow_flagging="never",
    )
    return demo