sindhuhegde's picture
Rename app.py to app_test.py
4687821
raw
history blame
607 Bytes
import gradio as gr
import os
def video_identity(video):
src="/file=videos/test.mp4"
print(src)
vid = """<video width="320" height="240" controls> \
<source src="%s" type="video/mp4">\
</video>""" % src
# vid = ("<img src='/file=img.jpg' alt='image One'>")
return vid
demo = gr.Interface(video_identity,
gr.Video(),
gr.HTML(),
)
if __name__ == "__main__":
# with gr.Blocks() as demo:
# gr.HTML("<img src='/file=img.jpg' alt='image One'>")
demo.launch(allowed_paths=["."])