smacke / smacke/ffsubsync

allow one split to handle cases where intro sequence appears in middle of video

Open
#115 0 comments 1 reaction 1 assignee View on GitHub

@smacke is already working on this.

Since Jan 31, 2021.

enhancement
Dominant language
Python
Stars
7.9k
Forks
323
PR merge metrics
No merged PRs in 30d

Description

In most cases, a TV episode's intro sequence will occur at the start of the video, and ffs will handle these properly. However, if the intro sequence occurs in the middle, at least part of the sync will always be incorrect. If we are allowed to split the subtitles a single time, we should be able to handle the case where the intro sequence occurs in the middle, which should cover the majority of cases where splits are necessary.

The key is to figure out how to pick the split point. I think golden section search for the split point could be a good strategy. The other approach that could work well based on early tests is to try and search for "maximally self-concordant blocks", i.e., maximum-sized blocks for which the best sync on any sub-block agrees with the sync on the overall block. The latter approach has the advantage that it could generalize nicely to any number of splits, but the golden section search approach is probably easier to implement.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.