jhj0517 commited on
Commit
3f07ee0
1 Parent(s): 8eda133

add examples

Browse files
Files changed (1) hide show
  1. app.py +11 -0
app.py CHANGED
@@ -49,6 +49,17 @@ class App:
49
  with gr.Row():
50
  btn_align_pose = gr.Button("ALIGN POSE", variant="primary")
51
 
 
 
 
 
 
 
 
 
 
 
 
52
  btn_align_pose.click(fn=self.pose_alignment_infer.align_pose,
53
  inputs=[vid_dance_input, img_pose_input, nb_detect_resolution, nb_image_resolution,
54
  nb_align_frame, nb_max_frame],
 
49
  with gr.Row():
50
  btn_align_pose = gr.Button("ALIGN POSE", variant="primary")
51
 
52
+ with gr.Column():
53
+ examples = [
54
+ [os.path.join("examples", "dance.mp4"), os.path.join("examples", "ref.jpg"),
55
+ 512, 720, 0, 300]]
56
+ ex_step1 = gr.Examples(examples=examples,
57
+ inputs=[vid_dance_input, img_pose_input, nb_detect_resolution,
58
+ nb_image_resolution, nb_align_frame, nb_max_frame],
59
+ outputs=[vid_dance_output, vid_dance_output_demo],
60
+ fn=self.pose_alignment_infer.align_pose,
61
+ cache_examples="lazy")
62
+
63
  btn_align_pose.click(fn=self.pose_alignment_infer.align_pose,
64
  inputs=[vid_dance_input, img_pose_input, nb_detect_resolution, nb_image_resolution,
65
  nb_align_frame, nb_max_frame],