-
Notifications
You must be signed in to change notification settings - Fork 891
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Netflix Timing Fixer #4697
Comments
Hey. :) As you can see here, they should be working well: Here is the link of the beta: https://github.com/SubtitleEdit/subtitleedit/releases/download/3.5.18/SubtitleEditBeta.zip |
Thank you @OmrSi. So now Netflix Quality Checker is working great! About my suggestion, I was thinking about a button to correct the timings automatically the way I described instead of manual adjusting them. And we would use the checker to see if everything is alright at the end. The two together could be very powerful! |
@m0ck69 @matmaggi It's on the to-do list. For example, If the reading speed is above the threshold and you choose to auto-fix that, it would extend the out-cue, but what if the user had already extended the out-cue to 12 frames after the voice ended? Another example, what if the shot change was a fake shot change? it would adjust the timing based on it, but it shouldn't. Yet another example is your image: What should it do in this case? How would it know whether to extend the out-cue to 2 frames before the shot or 13 frames before it or 12 frames after it? And other examples of endless edge cases. |
Well, as stated, I was thinking about using it when we time subtitles exactly at the in-time and out-time, so it wouldn't be expected to have already 12 frames past it. In my image, I would do what I have described in the following NF guideline.
I think this tool is supposed to be used right after timing the whole file (or template), then translating in a file "fixed". So you'll adjust some lines when needed and then run the Netflix Quality Checker at last, fixing manually a few (hopefully) errors that could have passed. That's why I think this auto-correct timing would be really helpful. |
@matmaggi I already worked on an experimental version of SubTimingsBeautifier with a setting to leave X frames between the out cue and shot cut, but the other rules ("green zone", "red zone") were a PITA to implement. When creating a feature like this, I feel it should be configurable. For example, 12 frames is 0,5 second. Moving an in-cue 11 / 12 frames forward because coincidentally there is a shot cut will cause the subtitle to be shown 0,5 second after the speaker is audible. Same goes in reverse for the out-cues. This comes down to these basic guidelines: A subtitle should NEVER appear AFTER dialogue has started. Also, subtitles should stay on-screen for about 500 to 1000 ms after the dialogue has ended, to give the viewer the chance to actually read the subtitle. Furthermore, I never understood the "2 frames before shot cut" rule. This leads to unnecessary "flashing" on-screen for viewers. It's better to hide the subtitle exactly on the shot cut, so there's only 1 "flash". SubTimingsBeautifier was originally designed this way. TL;DR: A feature like this could be really useful, but it should not use Netflix's bad rules hardcoded. |
Some technical challenges: SubtitleEdit and SubRip use milliseconds under the hood. 25 FPS will give nicely rounded timecodes, but a lot of content is 23,976 / 24 FPS, which will lead to rounding issues. In practice, playing an SRT using a media player may result in some subtitles (dis)appearing too late or too early, which is bad when you're working with shot cuts, of course. SubTimingsBeautifier solved this by extracting the exact timecodes from the video file using ffmpeg. Using mpv in combination with the shortcuts to move frame by frame seems to give accurate timecodes, so I hope it's possible somehow to tap into that. |
@matmaggi @Flitskikker |
@Flitskikker Thank you.
About this statement, I totally agree, but that's not what my clients tell me to do, so I do what they tell me. haha
I really liked to extract the exact timecodes with SubTimingsBeautifier using ffmpeg. I don't think this will be a problem if we have a good quality tool. @OmrSi Yes, I understand. Thank you anyway. |
I worked out a prototype UI for this feature tonight. The following panel could be added somewhere in the settings: While Netflix doesn't use the red/green zone anymore, it helps visualizing setting the threshold (i.e. move the cue to 12 frames from the shot cut, or snap the cue to the shot cut). For the previews, I used Netflix's design from their style guide. The previews will show the settings and maybe allow interaction. Everything should be configurable like this, either for Netflix or to replicate SubTimingsBeautifier's logic. -- These settings will then be used by:
-- Finally, SubTimingsBeautifier's feature "Extend out-cues where/until possible by ...", which takes shot cuts into account, can be added to Tools > Adjust durations... as a checkbox. Any thoughts? Did I miss anything? |
@Flitskikker Wow! That's fantastic! I think that's perfect. It seems that everything is there. With some testing we can say for sure. |
Thank you for all your work, @Flitskikker. I'm not sure I 100% agree with one of your posts, however.
What about shot changes?
Maybe in some scenarios, but this might be difficult for dialogue in quick succession or when the dialogue continues very briefly into a shot change.
One Blu-ray authoring software requires a minimum of four frames, so I would need this.
Agreed. |
Hi @Flitskikker, sorry to disturb you, but do you have any news about your amazing panel? Thanks. |
@matmaggi Unfortunately I've had very little spare time in the last few months because of work... 😪 If I recall correctly, I was almost done with the UI, so that leaves the actual logic and further integration, such as #5134, based on the selected settings. It's still on my radar! |
Hello, just checking. Any news on this? Thank you! |
@matmaggi I went ahead and actually blocked some space in my schedule next week to dive in it again. |
@matmaggi You can go to Tools > Beautify time codes... or use the icon on the toolbar (old or new style 😉): Then you can choose to extract the exact timings using ffprobe (useful for 23.976 FPS content due to rounding -- not really needed for 25 FPS) and enable shot change snapping: You can configure the profile as shown before: Netflix' rules (not my personal preference) are shown in the example. There are also presets for e.g. SDI and the "default" preset from good ol' SubTimingsBeautifier. Netflix already moved away from red and green zones in the meantime, but I find it useful to visualize what is actually happening (move towards or away from shot changes). Still a bit overwhelming of course, so there is also a "simple mode" helper wizard thingy: Again NF rules as an example, loaded by the handy button (I presume most subtitlers are forced to work with similar rules these days). Beautifying itself seems to work, but I can't really screenshot that of course. Snapping in the wave form is now also done according to this profile, so out cues would snap 2 frames before shot changes with this profile. Before I make a PR for it, I will do some testing with several files and also compare it with STB's output. The logic was a real braintwister to write with all those zones and conditions, so there are probably some edge cases that I need to tweak. There are still some things that could be improved, such as adding it to the batch converter and command line, an option to beautify only selected lines... But let's focus on version 1.0 first, I think. I also struggle with writing unit tests for this. There are some simple functions that I can write tests for (e.g. Also, @OmrSi, some shortcuts depending on shot changes might need to be updated to also use the new rules. Again my apologies that it took so long... Hopefully a release is now finally nearby. |
OMG, @Flitskikker this is beyond amazing and super helpful for lots of people, I think. Looking forward to seeing it! |
This is looking amazing. Thank you, @Flitskikker |
Hello, I think this is a mission for @OmrSi or anyone interested.
My idea is a "Netflix Timing Fixer" following the newest Netflix Timing Guidelines (that can be seen here)
How would it work?
We would time the whole subtitle file to audio (in and out) regardless of the shot changes/scene changes. Then we would apply this "Netflix Timing Fixer" and it will follow this rules:
*SC = shot change/scene change in this case.
IN-CUES:
Always have to be 12 frames before the SC or 12 frames after the SC or on the SC, so:
OUT-CUES:
Always have to be 12 frames before SC or 12 frames after SC or 2 frames before SC (never on the SC), so:
Condition:
Respecting 2 or 12 frame gap between subtitles (3-11 frames gap are not allowed)
How can it be done?
I actually know nothing about programming, but using or incorporating some parts of SubTimingsBeautifier (by @Flitskikker) into SE could be really helpful, since it already does some part of the job. Having to readequate to above rules. Also, the new Netflix Quality Checker in the SE has some great info too #4470.
Why do this?
Because Netflix has become somewhat the head of the subtitling industry and several clients always say "follow Netflix guidelines", so it could be very helpful for all that uses these timing guidelines.
I tried to make this easy to explain, so I hope it's clear enough. Thank you all for all your effort throughout the years.
The text was updated successfully, but these errors were encountered: