Skip using logo only: not working

To discuss the tuning of comskip and for posting your ini files
Post Reply
eelioss
Posts: 4
Joined: Tue Jun 19, 2018 6:34 pm

Skip using logo only: not working

Post by eelioss »

I have a video of 10min, with 3min of show at the beginning, and 7min of commercials at the end. In this channel, the logo is always present in shows, and never present in commercials. Logo detection is done correctly (according to the exported CSV), but it does not want to use it for skipping commercials:

Code: Select all

End logo block 0    frame 4350  Length - 0:02:46.95                             
                                                                                
Not enough or too much logo's found (0.28), disabling the use of Logo detection
Any hint to make it work?

Thanks.

some relevanat parameters of my comskip.ini:

Code: Select all

detect_method=2         ;1=black frame, 2=logo, 4=scene change, 8=fuzzy logic, 16=closed captions, 32=aspect ration, 64=silence, 128=cutscenes, 255=all
max_commercialbreak=600         ;maximum length in seconds to consider a segment a commercial break
min_show_segment_length=600     ; any segment longer than this will be scored towards show.
subtitles=1 # my logo is a the top
logo_percentile=0.99
logo_threshold=0.75
erik
Site Admin
Posts: 3368
Joined: Sun Aug 21, 2005 3:49 pm

Re: Skip using logo only: not working

Post by erik »

What is your logo_fraction?
In general comskip does not work out of the box with these very short recordings so more elaborate tuning will be needed
eelioss
Posts: 4
Joined: Tue Jun 19, 2018 6:34 pm

Re: Skip using logo only: not working

Post by eelioss »

Thanks erik!
I just set logo_fraction to 0.1, and now I get this log:

Code: Select all

******************* End of Logo Processing ***************

End logo block 0        frame 4350      Length - 0:02:46.95
Distribution of Black Frame   cutting:   1 positive and   0 negative, ratio is 9.9900
Confidence of Black Frame   cutting:   0 out of   0 are strict, too low
Distribution of Scene Change  cutting:   0 positive and   0 negative, ratio is 9.9900
Confidence of Scene Change  cutting:   0 out of   0 are strict, too low
Distribution of Uniform Frame cutting:   0 positive and   0 negative, ratio is 9.9900
Confidence of Uniform Frame cutting:   0 out of   0 are strict, too low

Logos detected on the following frames
--------------------------------------
Logo start -    176     end -   4350    length - 0:02:46.95     before:7.0 s     after:425.8 s

Fuzzy scoring of the blocks
---------------------------
Block 0 has logo.
Block 0 score:  Before - 1.00   After - 0.01
Threshold used - 1.0500 After rounding - 1.0500


        ---------------------
        Initial Commercial List
        ---------------------
No change

Logo fraction:              0.2800      
Maximum volume found:        14024
Average volume:               3586
Sound threshold:               500
Silence threshold:             100
Minimum volume found:          320
Average frames with silence:    96
Black threshold:                25
Minimum brightness found:       16
Minimum bright pixels found:     0
Minimum dim level found:         0
Average brightness:           1289
Uniformity level:              500
Average non uniformity:        517
Maximum gap between logo's:     -1
Suggested logo_threshold:   0.7750
Suggested shrink_logo:      5.00
Max commercial size found:      -1
Dominant aspect ratio:      0.0000
Score threshold:            1.0500
Framerate:                  25.000
Total commercial length:    0:00:00.00
Block list after weighing
----------------------------------------------------
  #     sbf  bs  be     fs     fe    sc      len   scr cmb   ar                   cut bri  logo   vol  sil corr stdev        cc
  0:+     0   0   0      1  14997   0.01  599.800  0.20   0 0.00            L        b  12890 0.28 35860 960  0.000   128           

14997 Frames Processed
Now the segment seems to be discarded because of its score... isn't it?
In general comskip does not work out of the box with these very short recordings so more elaborate tuning will be needed
I understand. What would you recommend to deal with commercial skipping in short videos?
erik
Site Admin
Posts: 3368
Joined: Sun Aug 21, 2005 3:49 pm

Re: Skip using logo only: not working

Post by erik »

Set all validate settings to 0
Use the punish no logo setting
Set cut before and after logo
eelioss
Posts: 4
Joined: Tue Jun 19, 2018 6:34 pm

Re: Skip using logo only: not working

Post by eelioss »

I added:

Code: Select all

validate_silence=0          ; Default, set to 0 to force using this clues if selected above.
validate_uniform=0          ; Default, set to 0 to force using this clues (like pure white frames) if blackframe is selected above.
validate_scenechange=0      ; Default, set to 0 to force using this clues if selected above.
before_logo=0                                                                      
after_logo=0        ; set to number of seconds after logo disappears comskip should start to search for silence to insert an additional cutpoint
punish_no_logo=1
logo_fraction=0.1
And still it doesn't says 'show' when logo is ON, and 'commercial' when logo is OFF :(

Code: Select all

End logo block 0        frame 4350      Length - 0:02:46.95
Frame   4977 - Cutpoint added 25 seconds after Logo disappears at change percentage of 2
Distribution of Black Frame   cutting:   1 positive and   0 negative, ratio is 9.9900
Confidence of Black Frame   cutting:   0 out of   0 are strict, too low

Logos detected on the following frames
--------------------------------------
Logo start -    176     end -   4350    length - 0:02:46.95     before:7.0 s     after:25.0 s

Fuzzy scoring of the blocks
---------------------------
Block 0 has logo.
Block 0 score:  Before - 1.00   After - 1.20
Block 1 has no logo.
Block 1 score:  Before - 1.00   After - 2.00
Threshold used - 1.0500 After rounding - 1.0500


        ---------------------
        Initial Commercial List
        ---------------------
 0)      1       14997  0:09:59.80
Shortening commercial block 0 because the first 2 seconds should always be kept.
No change

Logo fraction:              0.2800      
Maximum volume found:        14024
Average volume:               3586
Sound threshold:               500
Silence threshold:             100
Minimum volume found:          320
Average frames with silence:    96
Black threshold:                25
Minimum brightness found:       16
Minimum bright pixels found:     0
Minimum dim level found:         0
Average brightness:           1285
Uniformity level:              500
Average non uniformity:        516
Maximum gap between logo's:     -1
Suggested logo_threshold:   0.7750
Suggested shrink_logo:      5.00
Max commercial size found:      -1
Dominant aspect ratio:      0.0000
Score threshold:            1.0500
Framerate:                  25.000
Total commercial length:    0:00:00.00
Block list after weighing
----------------------------------------------------
  #     sbf  bs  be     fs     fe    sc      len   scr cmb   ar                   cut bri  logo   vol  sil corr stdev        cc
  0:00    0   0   0      1   4976   1.20  199.000  0.07   0 0.00            L    l       625- 0.84 2733- 97+  0.000    62           
  1:--    1   1   0   4977  14997   2.00  400.760  0.27   0 0.00            L        b  1613+ 0.00 4010+ 95-  0.000   161           

14997 Frames Processed
################################################################
Time at end of run:
Thu Jun 21 08:52:12 2018
################################################################
Even if the logo is correctly detected, according to the CSV: https://ibb.co/gbbc5T
erik
Site Admin
Posts: 3368
Joined: Sun Aug 21, 2005 3:49 pm

Re: Skip using logo only: not working

Post by erik »

Setting before/after to 0 disables the logo based cutting.
Try setting to 10
eelioss
Posts: 4
Joined: Tue Jun 19, 2018 6:34 pm

Re: Skip using logo only: not working

Post by eelioss »

It seems to work now :) Thanks!!
markn62
Posts: 16
Joined: Sun Jun 30, 2019 8:17 pm

Re: Skip using logo only: not working

Post by markn62 »

@eelioss could you provide your .ini file? I can't get my "logo only" commercial cuts to work. Thanx.
Post Reply