multimodalart HF staff commited on
Commit
0c7a657
1 Parent(s): 05a30dd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -30,7 +30,7 @@ device = "cuda"
30
 
31
  #hf_hub_download(repo_id="stabilityai/stable-video-diffusion-img2vid-xt", filename="svd_xt.safetensors", local_dir="checkpoints", token=os.getenv("HF_TOKEN"))
32
 
33
- def sample(
34
  input_path: str,
35
  num_frames: Optional[int] = 25,
36
  num_steps: Optional[int] = 30,
@@ -142,6 +142,6 @@ Generate 25 frames of video from a single image with SDV-XT. [Join the waitlist]
142
  with gr.Column():
143
  video = gr.Video()
144
  image.upload(fn=resize_image, inputs=image, outputs=image)
145
- generate_btn.click(fn=sample, inputs=[image], outputs=video, api_name="video")
146
 
147
  demo.launch()
 
30
 
31
  #hf_hub_download(repo_id="stabilityai/stable-video-diffusion-img2vid-xt", filename="svd_xt.safetensors", local_dir="checkpoints", token=os.getenv("HF_TOKEN"))
32
 
33
+ def run_sampling(
34
  input_path: str,
35
  num_frames: Optional[int] = 25,
36
  num_steps: Optional[int] = 30,
 
142
  with gr.Column():
143
  video = gr.Video()
144
  image.upload(fn=resize_image, inputs=image, outputs=image)
145
+ generate_btn.click(fn=run_sampling, inputs=[image], outputs=video, api_name="video")
146
 
147
  demo.launch()