MMpose / app.py
xmrt's picture
docker and app
c2134b3
raw
history blame
376 Bytes
import mmpose
print(mmpose.__version__)
from mmpose.apis import MMPoseInferencer
inferencer = MMPoseInferencer(
pose3d='human')
import gradio as gr
def greet(photo):
result_generator = inferencer(photo)
vis, pred = next(result_generator)
return vis
demo = gr.Interface(fn=greet, inputs=gr.Image(source="webcam"), outputs=gr.Image())
demo.launch()