CoolFace
Apppublic

akhaliq/Keypoint_Communities

sourceHugging Faceupdated 5y agoView on Hugging Face
7likes
app.py24 linesDownload Raw Back to root
1import gradio as gr2import os3 4def inference(image):5    os.system("python -m openpifpaf.predict "+image.name+" --checkpoint=shufflenetv2k30-wholebody --line-width=2  -o out.jpg")6    return "out.jpg"7 8 9title = "Keypoint Communities"10description = "Gradio demo for Keypoint Communities:  a fast bottom-up method that jointly detects over 100 keypoints on humans or objects, also referred to as human/object pose estimation. To use it, simply upload your image, or click one of the examples to load them. Read more at the links below."11article = "<p style='text-align: center'><a href='https://arxiv.org/abs/2110.00988' target='_blank'>Keypoint Communities</a> | <a href='https://github.com/DuncanZauss/Keypoint_Communities' target='_blank'>Github Repo</a></p>"12 13examples=[['soccer.jpeg']]14 15gr.Interface(16    inference, 17    gr.inputs.Image(type="file", label="Input"), 18    gr.outputs.Image(type="file", label="Output"),19    title=title,20    description=description,21    article=article,22    enable_queue=True,23    examples=examples24    ).launch(debug=True)