Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

gradio无法输出最终视频。 #94

Closed
leetraman822 opened this issue Jul 11, 2024 · 8 comments
Closed

gradio无法输出最终视频。 #94

leetraman822 opened this issue Jul 11, 2024 · 8 comments
Labels

Comments

@leetraman822
Copy link

你好,我安装了2024年7月10日的github更新,运行动画时正常,当进度条加载完成后,在动画输出区显示错误,终端显示为:
Traceback (most recent call last):
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\site-packages\gradio\queueing.py", line 541, in process_events
response = await route_utils.call_process_api(
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\site-packages\gradio\route_utils.py", line 276, in call_process_api
output = await app.get_blocks().process_api(
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\site-packages\gradio\blocks.py", line 1928, in process_api
result = await self.call_function(
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\site-packages\gradio\blocks.py", line 1514, in call_function
prediction = await anyio.to_thread.run_sync(
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\site-packages\anyio\to_thread.py", line 56, in run_sync
return await get_async_backend().run_sync_in_worker_thread(
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\site-packages\anyio_backends_asyncio.py", line 2177, in run_sync_in_worker_thread
return await future
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\site-packages\anyio_backends_asyncio.py", line 859, in run
result = context.run(func, *args)
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\site-packages\gradio\utils.py", line 833, in wrapper
response = f(*args, **kwargs)
File "E:\Softwares\LivePortrait\app.py", line 37, in gpu_wrapped_execute_video
return gradio_pipeline.execute_video(*args, **kwargs)
File "E:\Softwares\LivePortrait\src\gradio_pipeline.py", line 57, in execute_video
video_path, video_path_concat = self.execute(self.args)
File "E:\Softwares\LivePortrait\src\live_portrait_pipeline.py", line 217, in execute
flag_has_audio = (not flag_load_from_template) and has_audio_stream(args.driving_info)
File "E:\Softwares\LivePortrait\src\utils\video.py", line 176, in has_audio_stream
result = subprocess.run(cmd, capture_output=True, text=True)
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\subprocess.py", line 505, in run
with Popen(*popenargs, **kwargs) as process:
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\subprocess.py", line 951, in init
self._execute_child(args, executable, preexec_fn, close_fds,
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\subprocess.py", line 1436, in _execute_child
hp, ht, pid, tid = _winapi.CreateProcess(executable, args,
FileNotFoundError: [WinError 2] 系统找不到指定的文件。

使用最初的版本没有问题,请问这个问题该如何解决呢。

@leetraman822
Copy link
Author

leetraman822 commented Jul 11, 2024

微信截图_20240711113156

@leetraman822
Copy link
Author

微信截图_20240711113208

@leetraman822
Copy link
Author

使用python inference.py指令也无法输出,显示错误为:
Traceback (most recent call last):
File "E:\Softwares\LivePortrait\inference.py", line 33, in
main()
File "E:\Softwares\LivePortrait\inference.py", line 29, in main
live_portrait_pipeline.execute(args)
File "E:\Softwares\LivePortrait\src\live_portrait_pipeline.py", line 217, in execute
flag_has_audio = (not flag_load_from_template) and has_audio_stream(args.driving_info)
File "E:\Softwares\LivePortrait\src\utils\video.py", line 176, in has_audio_stream
result = subprocess.run(cmd, capture_output=True, text=True)
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\subprocess.py", line 505, in run
with Popen(*popenargs, **kwargs) as process:
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\subprocess.py", line 951, in init
self._execute_child(args, executable, preexec_fn, close_fds,
File "C:\Users\Administrator\anaconda3\envs\liveportrait\lib\subprocess.py", line 1436, in _execute_child
hp, ht, pid, tid = _winapi.CreateProcess(executable, args,
FileNotFoundError: [WinError 2] 系统找不到指定的文件。

@cleardusk
Copy link
Member

It seems the ffmpeg is not installed on your Windows

@leetraman822
Copy link
Author

It seems the ffmpeg is not installed on your Windows

谢谢😊,果然是我忘记安装ffmpeg了。

@cleardusk
Copy link
Member

Great!

Cound you tell us hot to install ffmepg on Windows : ) Since we do not have a Windows env now. @leetraman822

@leetraman822
Copy link
Author

Great!

Cound you tell us hot to install ffmepg on Windows : ) Since we do not have a Windows env now. @leetraman822

哈哈其实很简单,我将ffmpeg.exe和ffprobe.exe这两个文件复制到LivePortrait根目录就解决了😊。

@FurkanGozukara
Copy link

how to install ffmpeg : https://youtu.be/-NjNy7afOQ0

12:34 How to check if FFmpeg is installed and set on Windows
12:45 How to install and setup FFmpeg on Windows
13:40 How to add downloaded FFmpeg exes to the system environment variables path

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants