Page 1 of 1

Delete before first and after last commercial in seconds.

Posted: Fri May 10, 2013 10:34 pm
by Jagad
A broadcaster of mine are throwing me curveballs where "delete_show_after_last_commercial=1"
doesn't delete after show trailers entirely, due to logo detection.

I did notice there's two options to keep first and last seconds of a recording:
always_keep_first_seconds=0
always_keep_last_seconds=0

Looking for:
always_delete_first_seconds=60
always_delete_last_seconds=120
in order to be sure the recording pre and post rolls are deleted sufficient. Im sure there's some way to tune the ini to handle my issue, but I wanna have an easy and foolproof way to do it. Any chance?

Re: Delete before first and after last commercial in seconds

Posted: Sat May 11, 2013 7:44 am
by erik
Can't you reduce the recording time?

Re: Delete before first and after last commercial in seconds

Posted: Sat May 11, 2013 10:48 am
by Jagad
Setting the PVR software with no pre and post roll time, peculiar things starts to happen when scheduling recordings. Minimum pre and post roll time for everything to work as it should is 1 minute. Unfortunately a 1 minute postroll wasn't enough cuz I sometimes kept missing the end of the show, due to different delays in the schedule.

IMHO something like
always_keep_first_seconds=0
always_keep_last_seconds=0
is really needed for deletion of the first and last seconds as well, cuz such an option overrules every other comskip commercial detection method there is that can spoil the party.
It is obvious
delete_show_before_first_commercial=1
delete_show_after_last_commercial=1
doesn't have that overruling power.

Re: Delete before first and after last commercial in seconds

Posted: Sat May 11, 2013 11:17 am
by erik
But with the different delays in the schedule you will still miss the end of the show?
Or do you in such a case manually re-position to still see the end?

Re: Delete before first and after last commercial in seconds

Posted: Sat May 11, 2013 12:15 pm
by Jagad
erik wrote:But with the different delays in the schedule you will still miss the end of the show?
Or do you in such a case manually re-position to still see the end?
The PVR pre and post roll setting applies to all recordings. The actual broadcaster in this example rarely has any delays. If such a case will emerge I always store the untouched original recording and manually edit out the commercials with VRD.

Re: Delete before first and after last commercial in seconds

Posted: Sat Jan 25, 2014 12:04 pm
by Jagad
I finally managed to find out why Comskip often doesn't delete previous show and the show after the current one, despite having them set like this:

delete_show_before_first_commercial=1
delete_show_after_last_commercial=1

As it seems it has very little to do with logo detection, black frames or max_silence or lack of thereof, but the comment I found in the tuning.html.
Both above algorithms will be automatically disabled if the commercial is not within the outside 15% of the recording.
Even though I'm not fully understanding this ambiguous algorithm conditioning, it's pretty clear Comskip will disable the delete alogorithms when certain condions are met. Sometimes previous show is deleted, sometimes only the show after the current one, but the most common case is both won't get deleted. The problem is more frequent on shorter recordings (30min) rather than 1 hr recordings. Comskip is always launched on finished recordings (not using LiveTV detection at all).

Next algorithm "delete_show_before_or_after_current=1" if having it enabled definitely interfer with the first two alogorithms and tend to make the situation even more confusing.

Only solution I have come up with is using my own trimming/delete script on the Comskip output (VPrj). So Erik, perhaps you could elaborate on the matter and if possible also tell me if there's a chance to review these algorithms, so the automatic disabeling doesn't trigger so often?

Regards
Jagad

Re: Delete before first and after last commercial in seconds

Posted: Sat Jan 25, 2014 2:06 pm
by erik
The delete before / after are designed to only remove small fractions of the recording.
Therefore the 15% rule.
One option for you is to tune the amount you record before/after the actual show. Presumably reduce the duration.
My 15% rule may be better changed to first/last 5 or 10 minutes to facilitate short recordings to be processed.

Re: Delete before first and after last commercial in seconds

Posted: Sat Jan 25, 2014 2:53 pm
by Jagad
erik wrote:The delete before / after are designed to only remove small fractions of the recording.
Therefore the 15% rule. One option for you is to tune the amount you record before/after the actual show. Presumably reduce the duration.
Unfortunately with the PVR software I'm using the option to tune the amount you record before and after the actual show is a no go. I have 1 min pre-roll and 2 min post-roll today. If decreasing pre-roll to 0 min the autotimer doesn't produce any recording timers, which is unthinkable. With current setting I got on average about 2,5-3 minutes of content (inbetween- show-commercial included) before the actual show starts. If I have understood the 15% rule alright, 3 minutes which is less than 15% of 33 minutes of recording should not trigger the rule, but it does so quite frequently anyway. The post-roll I've set to 2 min because some broadcasters have been rather messy when it comes to delays in EPG. That means I sometimes can have 4-6 minutes of commercial break between the shows and post-show after the actual show and that will trigger the 15% rule almost every time.

One very problematic part is when 15% rule gets triggered the algorithm seem to remove cut markers for the short commercial break between the shows (or heuristics possibly never gets a chance to apply the cuts). When that happens I end up with only the scene markers where the commercial is and no cuts at all in beginning and end of recording. The heuristics seems to fail in this case or my guess heuristics (applying cut blocks step) wont be allowed processing areas where 15% rule have been triggered.
erik wrote:My 15% rule may be better changed to first/last 5 or 10 minutes to facilitate short recordings to be processed.
That would be a huge advancement if you could do that :D

Regards
Jagad

Re: Delete before first and after last commercial in seconds

Posted: Sat Feb 15, 2014 3:32 pm
by Jagad
erik wrote:My 15% rule may be better changed to first/last 5 or 10 minutes to facilitate short recordings to be processed.
This wasnt applied to the v.059, yes? Cant notice any difference in results comparing 058 with 059.

Re: Delete before first and after last commercial in seconds

Posted: Sun Feb 16, 2014 8:49 am
by erik
Nope, only the crash solved

Re: Delete before first and after last commercial in seconds

Posted: Fri May 23, 2014 8:41 pm
by Jagad
Any chance this will changed anytime soon?

Re: Delete before first and after last commercial in seconds

Posted: Fri May 23, 2014 10:17 pm
by erik
I'm rather busy now, but good you remember me on this