#8329 The srt subtitles were not read. The file may be empty or the format does not conform to the SRT specification:srtfile='

94.139**1 Posted at: 2 hours ago

The srt subtitles were not read. The file may be empty or the format does not conform to the SRT specification
:srtfile='C:/Users/kimnh/OneDrive/Máy tính/youtobe/_video_out/Traffickers Turn a Child Into a ‘Wolf Boy’ With Asphalt yt-mp4/en.srt'
content=''
Traceback (most recent call last):
File "videotrans\task\only_one.py", line 108, in run
File "videotrans\task\_stage_dubbing.py", line 24, in dubbing
File "videotrans\task\_stage_dubbing.py", line 43, in _tts
File "videotrans\util\_srt_parse.py", line 188, in get_subtitle_from_srt
RuntimeError: The srt subtitles were not read. The file may be empty or the format does not conform to the SRT specification
:srtfile='C:/Users/kimnh/OneDrive/Máy tính/youtobe/_video_out/Traffickers Turn a Child Into a ‘Wolf Boy’ With Asphalt yt-mp4/en.srt'
content=''

trk=[TransCreate]: uuid='77333a0eef', proxy_str=None, cfg=[TaskCfgVTT]当前工作模式: 翻译视频 单视频模式
原始输入文件名: C:/Users/kimnh/OneDrive/Máy tính/youtobe/Traffickers Turn a Child Into a ‘Wolf Boy’ With Asphalt yt.mp4,
输出结果保存到文件夹: C:/Users/kimnh/OneDrive/Máy tính/youtobe/_video_out/Traffickers Turn a Child Into a ‘Wolf Boy’ With Asphalt yt-mp4,
临时文件夹: C:/Users/kimnh/Downloads/win-pyvideotrans-v4.16/tmp/8956/77333a0eef
已选 清理已存在
未启用CUDA加速
未选 降噪
STT Service:faster-whisper(Built-in), large-v3-turbo, 发音语言: Simplified Chinese,
TranslateSrt:Local LLM (OpenAI-compatible),原始语言:Simplified Chinese,目标语言:English, 已选 SendSRT
TTS Service:Edge-TTS (Free), 角色:Brian(Male/US), 配音语言:English, 未选 二次语音识别
音量:+0%, 语速:+0%, 已选 音频加速, 已选 视频慢速
已选 移除每条字幕配音开头和结尾静音缓冲
静音移除力度: default
字幕: No Subtitles , precent=15, hasend=False, should_recogn=True, should_trans=True, should_dubbing=True, should_hebing=True, is_copy_video=True, video_codec_num=264, ignore_align=False, is_audio_trans=False, clone_ref='', should_recogn2=False, do_diarize=True
video_duration_ms=912040


=
system:Windows-10-10.0.26200-SP0
version:v4.16
frozen:True
language:en_US
root_dir:C:/Users/kimnh/Downloads/win-pyvideotrans-v4.16

1 Replies

#1 DeepSeek reply at 2 hours ago

The direct cause: the file en.srt is empty (content=''). The dubbing stage found nothing to read, so it aborted. The empty file was produced by the translation stage — your translation channel is Local LLM (OpenAI-compatible), which returned blank output for every subtitle line.

Two likely triggers, check both:

  1. Wrong spoken language (most likely)
    Your log shows STT Service: faster-whisper, large-v3-turbo, 发音语言: Simplified Chinese, but the source video appears to be English audio. Forcing Whisper to Chinese on English audio produces garbage text, and the "Chinese→English" translation then returns empty lines.
  2. Set Spoken Language = English (the real audio language), and Target Language = the language you actually want. Source and target must not be confused.
  3. Local LLM fails instruction-following
    Small locally deployed models (7B-class) frequently return empty text or ignore the required SRT format.
  4. Switch the translation channel to a strong AI model (DeepSeek / OpenAI / Gemini), or
  5. If you must keep the local model: open videotrans/prompts/srt/localllm.txt (used when SendSRT is checked) and videotrans/prompts/text/localllm.txt, and simplify the prompt — do NOT alter or delete anything inside {}.
  6. In Menu → Tools → Advanced Options → Translation, set AI translation batch lines to 1 (or 10–20), and uncheck SendSRT / AI translation includes all original subtitles — merging logic from weak models often yields blank lines.
  7. Simplify the path (important)
    C:/Users/kimnh/OneDrive/Máy tính/youtobe/...‘Wolf Boy’... contains spaces, Vietnamese diacritics, curly quotes ‘ ’ and OneDrive sync. Move the video to a shallow, pure-English path such as D:/videos/myvideo.mp4 and rename the file. Also note you had Clear Output checked — that wipes previously generated/intermediate SRTs, so re-running is the only way back.

Verification: after re-running the translation stage only, open ..._video_out/-mp4/en.srt and confirm it contains numbered blocks with timecodes. If it is still empty → translation channel problem; if it contains text but dubbing still fails → send the new log.

If the above does not resolve it, provide the bottom ~30 lines of the latest file in logs/ (address the exact channel and error shown).

请查阅相关文档:

Thinking...
Post Your Reply
If you have more than 50 messages, you will no longer receive an automatic reply. Please ask a new question!
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 via ko-fi.com

Related resource