warmshao / FasterLivePortrait

Bring portraits to life in Real Time!onnx/tensorrt support!实时肖像驱动!
455 stars 42 forks source link

[V2V] Output video freezes instead of cutting-off its length | FPS asynchrony #69

Closed tivikoff closed 1 month ago

tivikoff commented 1 month ago

Hello, I noticed two scenarios with Source and Driving videos in Video 2 Video mode:

  1. Source longer than Driving = Output cuts-off by the length of Driving video (As expected)
  2. Source shorter than Driving = Output freezes after the end of Source, but sound continues to play for the full length of Driving video. (Expected: Output cuts off by the Source length)

Maybe it is possible to make Output length to cut-off by the length of the shortest input (either Source or Driving)?

Similar situation - when FPS of Source is different than Driving. i.e. Source is 24 fps, Driving is 30 fps. Output becomes 30 fps, by speeding-up source and freezing output image since length of sourse becomes shorter due to fps conversion.

Maybe make some sort of fps check/comparison like it's implemented in ComfyUI node, and/or option to choose which fps/length to keep for the Output? Just my thoughts

Thank you!

warmshao commented 1 month ago

Hello, I noticed two scenarios with Source and Driving videos in Video 2 Video mode:

  1. Source longer than Driving = Output cuts-off by the length of Driving video (As expected)
  2. Source shorter than Driving = Output freezes after the end of Source, but sound continues to play for the full length of Driving video. (Expected: Output cuts off by the Source length)

Maybe it is possible to make Output length to cut-off by the length of the shortest input (either Source or Driving)?

Similar situation - when FPS of Source is different than Driving. i.e. Source is 24 fps, Driving is 30 fps. Output becomes 30 fps, by speeding-up source and freezing output image since length of sourse becomes shorter due to fps conversion.

Maybe make some sort of fps check/comparison like it's implemented in ComfyUI node, and/or option to choose which fps/length to keep for the Output? Just my thoughts

Thank you!

Should have fixed it. Please download the latest source code and then unzip it to overwrite the Windows package. You only need to download the code, which is essentially a patch to avoid having to download the large Windows package again.

tivikoff commented 1 month ago

Yeah, looks like both issues are fixed now. Well done and thanks!