ffsubsync icon indicating copy to clipboard operation
ffsubsync copied to clipboard

Framerate was not specified and cannot be read from the MicroDVD file error when used on a .sub file

Open Nicryc opened this issue 2 years ago • 0 comments

Environment (please complete the following information):

  • OS: Windows 10 WSL Debian
  • python version 3.9.2
  • subsync version 0.4.20

Describe the bug I get a Framerate was not specified and cannot be read from the MicroDVD file. error when trying to use ffsubsync on a .sub file, although I used --frame-rate FRAMERATE to specify the frame-rate.

To Reproduce What I have tried:

ffs --frame-rate 31250 "video.mkv" -i "unsync.sub" -o "sync.sub"
ffs --frame-rate 31250 --skip-infer-framerate-ratio "video.mkv" -i "unsync.sub" -o "sync.sub"
ffs --frame-rate 31250 "reference.srt" -i "unsync.sub" -o "sync.sub"

Expected behavior Frame-rate should be read from the command line argument and the program should carry on.

Output

[13:16:58] INFO     extracting speech segments from reference 'video.mkv'...
           INFO     Checking video for subtitles stream...                                              speech_transformers.py:259
           INFO     Video file appears to lack subtitle stream                                          speech_transformers.py:264
100%|██████████████████████████████████████████████████████████████████████████████████▉| 5460.0/5460.051 [01:01<00:00, 88.96it/s]
[13:18:00] INFO     ...done                                                                                       ffsubsync.py:444
           INFO     extracting speech segments from subtitles file(s)                                             ffsubsync.py:134
                    ['unsync.sub']...
           INFO     detected encoding: WINDOWS-1252                                                          subtitle_parser.py:85
           ERROR    Framerate was not specified and cannot be read from the MicroDVD file.                        ffsubsync.py:223

Nicryc avatar Jun 28 '22 11:06 Nicryc