Language-agnostic automatic synchronization of subtitles with video, so that subtitles are aligned to the correct starting point within the video. The implementation for this project was started during HackIllinois 2019, for which it received an Honorable Mention (ranked in the top 5 projects, excluding projects that won company-specific prizes).
First, make sure ffmpeg is installed. On MacOS, this looks like:
brew install ffmpeg
Next, grab the script. It should work with both Python 2 and Python 3:
pip install git+https://github.com/smacke/subsync
subsync video.mp4 -i unsynchronized.srt > synchronized.srt
subsync video.mp4 -i unsynchronized.srt -o synchronized.srt
For more check out https://github.com/smacke/subsync