import os os.system('gdown https://drive.google.com/uc?id=1hv0xwdbdf-Ym06Hpjy6wKyIklNmKmB99') import gradio as gr def greet(vid): os.rename(vid, 'temp.mp4') os.system("python demos/general.py --weights kapao_s_coco.pt --start 0 --end 2 --gif --fps --vid temp.mp4") return 'flash_mob_inference_kapao_s_coco.gif' title = "Kapao" description = "Gradio demo for Kapao: an efficient multi-person human pose estimation model that detects keypoints and poses as objects and fuses the detections to predict human poses. To use it, simply upload your video, or click one of the examples to load them. Read more at the links below." article = "

Rethinking Keypoint Representations: Modeling Keypoints and Poses as Objects for Multi-Person Human Pose Estimation | Github Repo

" iface = gr.Interface(fn=greet,inputs="video", outputs=gr.outputs.Image(type="file", label="output"), enable_queue=True, title=title, description=description, article=article, examples=[ ["dance2.mp4"] ]) iface.launch()