Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Capturing and Editing Video > VapourSynth

Reply
 
Thread Tools Search this Thread Display Modes
Old 25th April 2019, 06:33   #1  |  Link
Cary Knoop
Cary Knoop
 
Cary Knoop's Avatar
 
Join Date: Feb 2017
Location: Newark CA, USA
Posts: 397
IVTC does not remove all combed frames

What's the best strategy to fix a video that has bad edits?
After an IVTC (using VFM mode=5) not all combed frames are removed.

Applying a QTGMC afterward with InputType=1 destroys fine detail.

Last edited by Cary Knoop; 25th April 2019 at 07:10.
Cary Knoop is offline   Reply With Quote
Old 25th April 2019, 08:21   #2  |  Link
Sharc
Registered User
 
Join Date: May 2006
Posts: 3,997
for removing residual combing append
vinverse()
after IVTC

Last edited by Sharc; 25th April 2019 at 08:26.
Sharc is offline   Reply With Quote
Old 25th April 2019, 08:53   #3  |  Link
ChaosKing
Registered User
 
Join Date: Dec 2005
Location: Germany
Posts: 1,795
Vinverse looks often ugly.

This worked very good for me.

Code:
def conditionalDeint(n, f, orig, deint):
    if f.props._Combed:
        return deint#.sub.Subtitle("DEINT", margins=[20,20,70,20])
    else:
        return orig


clip = clip.vivtc.VFM(0, mode=3, cthresh=8,  blockx=32, blocky=32)
clip = clip.vivtc.VDecimate()
	
#deint = core.tdm.TDeintMod(clip, order=1, edeint=core.nnedi3.nnedi3(clip, field=1))
#deint = core.tdm.TDeintMod(clip, order=1, edeint=core.eedi3.eedi3(clip, 1))
deint = haf.QTGMC(clip, Preset='very slow', TR2=1, TFF=True, SourceMatch=3 ).std.SelectEvery( cycle=2, offsets=0)

combProps = core.tdm.IsCombed(clip, metric=1, cthresh=5, blockx=32, blocky=32, mi=90)
clip = core.std.FrameEval(clip, functools.partial(conditionalDeint, orig=clip, deint=deint), combProps)
VS docs have also an example http://www.vapoursynth.com/doc/plugins/vivtc.html
__________________
AVSRepoGUI // VSRepoGUI - Package Manager for AviSynth // VapourSynth
VapourSynth Portable FATPACK || VapourSynth Database

Last edited by ChaosKing; 25th April 2019 at 09:59.
ChaosKing is offline   Reply With Quote
Old 25th April 2019, 17:06   #4  |  Link
Cary Knoop
Cary Knoop
 
Cary Knoop's Avatar
 
Join Date: Feb 2017
Location: Newark CA, USA
Posts: 397
Changing the IsCombed() cthresh to 12 fixed the quality problem for me:

Code:
def IVTC(c):

	bit8 = core.fmtc.bitdepth(c, bits=8)	

	def conditionalDeint(n, f, orig, deint):
		if f.props._Combed:
		  return deint
		else:
		  return orig
			
	c = core.vivtc.VFM(clip=bit8, order=1, mode=0, cthresh=9,  blockx=32, blocky=32, clip2=c)
	c = core.vivtc.VDecimate(c)
		
	deint = hnw.QTGMC(c, Preset='very slow', TR2=1, TFF=True, SourceMatch=3 ).std.SelectEvery( cycle=2, offsets=0)
	
	combProps = core.tdm.IsCombed(c, metric=1, cthresh=12, blockx=32, blocky=32, mi=90)
	c= core.std.FrameEval(c, functools.partial(conditionalDeint, orig=c, deint=deint), combProps)
	return c
Thanks!
Cary Knoop is offline   Reply With Quote
Old 29th April 2019, 19:08   #5  |  Link
kolak
Registered User
 
Join Date: Nov 2004
Location: Poland
Posts: 2,843
Your ctresh is still quite high, which means it still can skip combed frames.
kolak is offline   Reply With Quote
Old 28th May 2019, 19:53   #6  |  Link
Cary Knoop
Cary Knoop
 
Cary Knoop's Avatar
 
Join Date: Feb 2017
Location: Newark CA, USA
Posts: 397
Quote:
Originally Posted by kolak View Post
Your ctresh is still quite high, which means it still can skip combed frames.
Yes, but in my case, this worked perfectly!
Cary Knoop is offline   Reply With Quote
Old 29th May 2019, 13:53   #7  |  Link
edcrfv94
Registered User
 
Join Date: Apr 2015
Posts: 84
1:Use tivtc tfm and tdecimate with ovr file output 24p part.(vivtc do not support tfm ovr file)
*You may need VFRHelper.
2:Try ivtc_txt60mc ref frame 0-4 to replace tfm can not match Frames.
3:If tivtc ovr and ivtc_txt60mc still not work try QTGMC bob to 60p.
Final: 24p + 30p + 60p VFR output with time code.
edcrfv94 is offline   Reply With Quote
Old 1st July 2019, 15:36   #8  |  Link
~ VEGETA ~
The cult of personality
 
~ VEGETA ~'s Avatar
 
Join Date: May 2013
Location: Planet Vegeta
Posts: 155
I still have blended frames even after using this script.

A small sample is here (45 seconds): https://mega.nz/#!WZR33IbD!yNX2SifTV...tc_4vcFHgd5LXo

I hope we can solve it.

I tried srestore in avs (not latest edition since it gives that avsplusversion error) but no use.
~ VEGETA ~ is offline   Reply With Quote
Old 13th August 2019, 04:48   #9  |  Link
real.finder
Registered User
 
Join Date: Jan 2012
Location: Mesopotamia
Posts: 2,587
Quote:
Originally Posted by ~ VEGETA ~ View Post
I still have blended frames even after using this script.

A small sample is here (45 seconds): https://mega.nz/#!WZR33IbD!yNX2SifTV...tc_4vcFHgd5LXo

I hope we can solve it.

I tried srestore in avs (not latest edition since it gives that avsplusversion error) but no use.
combed =/= blended, the thread don't talk about this kind of problem you have so indeed the script will make it worst, anyway the old code I have here

Code:
LWLibavVideoSource("D:\1_split.m2ts")
sanimebob()
srestore(omode=4, cache=10).srestore(frate=23.976)
Trim(199, 242)
seems do it http://www.solidfiles.com/v/7p7wAqDvKqqag
__________________
See My Avisynth Stuff
real.finder is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 21:10.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.