lagmoellertim/unsilence

Unsilencing some .mp4's result in a bad conversion

jessegoeman opened this issue · 4 comments

Description
When I pulled some lectures from a zoom recording, I am unable to unsilence them.
Upon opening the converted file, the file would play for a few frames and then freeze.

Example:
I download a 3 hr lecture, the calculated interval returns a reduction of 25% (making is a 2hr and someting lecture), upon continueing with those options, the file starts to get unsilenced.
2020-09-28_14-12

Upon completion, mediainfo shows me that the file is 400 hours long. When I open the file, the recording is stuck on the first frame.
filesize

A possible reason
I downloaded the lecture .mp4 with the following trick: https://www.youtube.com/watch?v=2ANwf9FJO3I&ab_channel=EatYourVegs

  • OS + version:
    NAME="KDE neon"
    VERSION="5.19"
    ID=neon
    ID_LIKE="ubuntu debian"
    PRETTY_NAME="KDE neon User Edition 5.19"
    VARIANT="User Edition"
    VERSION_ID="20.04"

  • Python version: 3.8

  • FFMPEG version: ffmpeg version 4.2.4-1ubuntu0.1 Copyright (c) 2000-2020 the FFmpeg developers

edit: when I download lectures that aren't a zoom recording (which isn't an option for every course), the tool works fine, so its either the duration, or the zoom .mp4 file thats responsible for this issue. Furthermore, when I use ffmpeg to convert the zoom video from 1080p to 720p (resulting in a completely fine and watchable .mp4), and then proceed to unsilence the clip with unsilence, it still results in a corrupted, 400 hour long, file.

I ran into a very similar scenario, also when trying to unsilence zoom recordings.

I also encountered the same problem trying to process a Zoom recording. Re-encoding the video beforehand with the following ffmpeg command solved it for me:

ffmpeg -i input.mp4 -c:v libx265 -c:a mp3 -map_metadata -1 -map_chapters -1 output.mp4

After this command unsilence works just fine. I guess the problem either arises from the chapter metadata or Zoom's encoding.