#5569 如何判断视频是哪个语言,听着像是日语,但是不确定

2a14:4900* Posted at: 2 hours ago

如何判断视频是哪个语言,听着像是日语,但是不确定

7 Replies

使用 pyVideoTrans 的批量语音转字幕功能即可判断:

  1. 打开左侧面板「批量语音转字幕」;
  2. 选择视频文件,在「发音语言」下拉菜单中选中自动检测
  3. 选择一个 ASR 渠道(如 faster-whisper(本地内置))并点击开始;
  4. 识别完成后,生成的 SRT 字幕文件名或日志中会显示检测到的语言代码(如 ja 代表日语)。

此功能专门保留了自动检测逻辑,能帮你准确判断语音语言。

看到内容是英文的,这个是英文的吗?,这是内容:1
00:00:00,000 --> 00:00:02,480
Shaders are essential to making beautiful games

2
00:00:02,860 --> 00:00:05,600
Both 2D and 3D projects rely on them extensively

3
00:00:05,640 --> 00:00:09,420
and if you don't understand the basics, your games will be severely limited

4
00:00:09,900 --> 00:00:14,120
So in this course, you will learn everything there is to know about 2D shaders in Godot

5
00:00:15,040 --> 00:00:18,600
We will create over 40 shaders that cover every major topic

6
00:00:19,040 --> 00:00:22,260
It starts with shader fundamentals, those of the basic projects

7
00:00:22,440 --> 00:00:25,680
We will cover vital math concepts like trigonometry and matrices

日志在什么地方看

这是英文,字幕内容为纯英文。
日志文件位于软件安装目录下的 logs/ 文件夹内,按日期命名(如 20250622.log)。

[DEBUG] 开始语音识别:渠道0
[DEBUG] [新进程任务 开始:STT use large-v3-turbo]
[DEBUG] 任务参数:kwargs={'detect_language': 'auto', 'model_name': 'large-v3-turbo', 'logs_file': 'D:/Program Files/PyVideoTrans/tmp/8636/e3c5ab4e9e/faster-auto-1782891513.7716625.log', 'is_cuda': True, 'no_speech_threshold': 0.6, 'condition_on_previous_text': False, 'speech_timestamps': None, 'audio_file': 'D:/Program Files/PyVideoTrans/tmp/8636/e3c5ab4e9e/1-1782891512.6600175.wav', 'local_dir': 'D:/Program Files/PyVideoTrans/models/models--mobiuslabsgmbh--faster-whisper-large-v3-turbo', 'compute_type': 'auto', 'jianfan': False, 'audio_duration': 300629, 'hotwords': None, 'prompt': None, 'beam_size': 5, 'best_of': 5, 'temperature': '', 'repetition_penalty': 1.0, 'compression_ratio_threshold': 2.4, 'max_speech_ms': 7000, 'device_index': 0}
[DEBUG] [faster_whisper]加载模型:当前 is_cuda=True,_compute_type='auto'
[DEBUG] faster-whisper模式下,对large-v3-turbo模型返回的断句结果重新修正
[DEBUG] 断句结果重新修正完毕
[DEBUG] 返回识别结果
[DEBUG] [新进程任务 结束:STT use large-v3-turbo],耗时29.415964603424072s
[DEBUG] 开始移除每条字幕末尾标点
[DEBUG] 新进程执行结束结束timeout=0

从日志片段来看,detect_language 设置为 'auto',系统已自动检测发音语言并完成了断句修正,但截取的日志中没有输出最终检测到的语言代码。建议查看更完整的日志文件(位于 logs/YYYYMMDD.log),搜索类似 detected language: enlanguage detected: ja 的关键字。如果没有,也可直接查看输出目录下的 SRT 字幕文件名或首行注释,其中会标注检测到的语言代码(如 en 对应英文)。更简便的方法:在批量语音转字幕面板中勾选自动检测后,生成的 SRT 文件名会包含语言后缀(如 *_en.srt)。

什么也看不出来,如果是日语,视频翻译时,使用英语,可以吗

不可以。发音语言(Spoken Lang)必须设为视频中实际说话的语言(日语),否则语音识别会完全错乱。目标语言(Target Lang)可设为英语,软件会自动完成翻译和配音。

Post Your Reply
Open source and free maintenance is not easy. If this project is helpful to you, please consider making a small donation to help the project continue to maintain and update. Dondate: ko-fi.com/jianchang512

Related resource