Open cykalet opened 10 months ago
(venv) D:\0software\video-subtitle-generator>python backend/main.py
请输入文件完整路径:D:\0software\video-subtitle-generator\test\test_cn.mp4
运行程序
【处理中】开始生成字幕,此步骤可能花费较长时间,请耐心等待...
Traceback (most recent call last):
File "D:\0software\video-subtitle-generator\backend\main.py", line 275, in
我一开始也是这样,忘了我重装系统了,我装了CUDA和cuDNN,去官网PyTorch找链接,然后在虚拟环境又安装torch框架,然后再运行就行了
Exception in thread Thread-2 (task): Traceback (most recent call last): File "C:\Users\Administrator\AppData\Local\Programs\Python\Python310\lib\threading.py", line 1016, in _bootstrap_inner self.run() File "C:\Users\Administrator\AppData\Local\Programs\Python\Python310\lib\threading.py", line 953, in run self._target(*self._args, **self._kwargs) File "D:\PythonFiles\video-subtitle-generator-main\gui.py", line 175, in task self.sg.run() File "D:\PythonFiles\video-subtitle-generator-main\backend\main.py", line 227, in run transcript = recognizer(data) File "D:\PythonFiles\video-subtitle-generator-main\backend\main.py", line 37, in call mel = whisper.log_mel_spectrogram(audio_data).to(self.model.device) File "D:\PythonFiles\video-subtitle-generator-main\backend\whisper\audio.py", line 131, in log_mel_spectrogram audio = torch.from_numpy(audio) RuntimeError: Numpy is not available
我也遇到了这个问题
这是来自QQ邮箱的假期自动回复邮件。 您好,我最近正在休假中,无法亲自回复您的邮件。我将在假期结束后,尽快给您回复。
成功打开文件:D:/0software/video-subtitle-generator/test/test_cn.mp4 选择识别的语言: 自动检测 选择识别模式: 标准 ['D:/0software/video-subtitle-generator/test/test_cn.mp4'] 【处理中】开始生成字幕,此步骤可能花费较长时间,请耐心等待... Exception in thread Thread-1 (task): Traceback (most recent call last): File "C:\Program Files\Python310\lib\threading.py", line 1016, in _bootstrap_inner self.run() File "C:\Program Files\Python310\lib\threading.py", line 953, in run self._target(*self._args, **self._kwargs) File "D:\0software\video-subtitle-generator\gui.py", line 175, in task self.sg.run() File "D:\0software\video-subtitle-generator\backend\main.py", line 227, in run transcript = recognizer(data) File "D:\0software\video-subtitle-generator\backend\main.py", line 37, in call mel = whisper.log_mel_spectrogram(audio_data).to(self.model.device) File "D:\0software\video-subtitle-generator\backend\whisper\audio.py", line 131, in log_mel_spectrogram audio = torch.from_numpy(audio) RuntimeError: Numpy is not available
使用了venv,不知道为什么会和系统上装的python有关系