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 > Avisynth Usage

Reply
 
Thread Tools Search this Thread Display Modes
Old 14th March 2005, 16:04   #1  |  Link
Chainmax
Huh?
 
Chainmax's Avatar
 
Join Date: Sep 2003
Location: Uruguay
Posts: 3,103
Trying to find the cause of a huge flaw in a filterchain...

I am in the process of filtering a VHS capture and while I'm pretty happy at the results there's one side effect to the filterchain I'm using: small details are greatly reduced. I have tried disabling the filters individually but haven't been able to pinpoint the cause of that. This is the filterchain I'm using:

SSIQ(diameter=11,strength=50,interlaced=false)

ConvertToYV12()

hqdn3d(0,0,3,3)

Cnr2("xxx",4,5,255)

BlindDeHalo3(rx=3.25,ry=3.25,strength=140,lodamp=4.0,hidamp=0.0,PPmode=2)

Undot()

DeGrainMedian()

Convolution3D(preset="animeLQ")

aWarpSharp(depth=16,cm=1)

FastLineDarken(strength=120,thinning=0)

LimitedSharpen(ss_x=2,ss_y=2,Dest_x=640,Dest_y=480,Strength=128)



You can download the encode [deleted]. Since the source occupies 190MBytes I can't upload it in its entirety, but ask me for whatever frame ranges you want from it (the source is 23,976 fps too) and I'll upload them (I suggest you include frames 189 and 256 in the request, they are good showcases of the issue). I would also greatly appreciate feedback on the quality of the encode.

Last edited by Chainmax; 28th March 2005 at 01:57.
Chainmax is offline   Reply With Quote
Old 14th March 2005, 16:35   #2  |  Link
Guest
Guest
 
Join Date: Jan 2002
Posts: 21,924
Your problem is caused by a deadly affliction called "filteritis". Your case appears to be terminal.
Guest is offline   Reply With Quote
Old 14th March 2005, 16:57   #3  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Hollola, Finland
Posts: 4,324
I was just about to say the same.

I would substitute all the denoisers with eDeen. All the details will be lost with that one alone
__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...
Boulder is offline   Reply With Quote
Old 14th March 2005, 19:31   #4  |  Link
Chainmax
Huh?
 
Chainmax's Avatar
 
Join Date: Sep 2003
Location: Uruguay
Posts: 3,103
I am not one to usually indulge in filter gorging, but SSIQ, BlindDeHalo3 and CNR2 have to be there. I used aWarpSharp and FastLineDarken with thinning = 0 because aWarpSharp's thinning looks better to me than FastLineDarken's. Undot is pretty much like using no filter at all speedwise and gives a little extra compressibility. That leaves out hqdn3d, DeGrainMedian and C3DYV12 up for discussion. I would appreciate it if you could download the encode, ask for some frames from the source and discuss this in a more informative way.


P.S: in case you have actually downloaded the encode, did it look that bad to you? I thought it looked awesome considering the source.
Chainmax is offline   Reply With Quote
Old 15th March 2005, 06:09   #5  |  Link
Chainmax
Huh?
 
Chainmax's Avatar
 
Join Date: Sep 2003
Location: Uruguay
Posts: 3,103
ChronoCross? SoulHunter? Can you guys help me out?
Chainmax is offline   Reply With Quote
Old 15th March 2005, 06:53   #6  |  Link
Backwoods
ReMember
 
Backwoods's Avatar
 
Join Date: Nov 2003
Posts: 416
Can you post the original frames next to the filtered that you speak of?

www.uploadhouse.com or www.imageshack.us
Backwoods is offline   Reply With Quote
Old 15th March 2005, 07:43   #7  |  Link
Chainmax
Huh?
 
Chainmax's Avatar
 
Join Date: Sep 2003
Location: Uruguay
Posts: 3,103
In my first post there's a download link to the filtered encode. Use it to give me feedback on its quality and to determine which parts of the unfiltered source you want.
Chainmax is offline   Reply With Quote
Old 15th March 2005, 08:27   #8  |  Link
ChronoCross
Does it really matter?
 
ChronoCross's Avatar
 
Join Date: Jun 2004
Location: Chicago, IL
Posts: 1,542
your definitely going to have to post the full source. I can't even judge what filters you should dump by that clip. all I know is it's super blurry and several of those filters can cause that.

if you need a place to host your clip pm me and let me know and I can host it for you.
ChronoCross is offline   Reply With Quote
Old 15th March 2005, 10:13   #9  |  Link
Soulhunter
Bored...
 
Soulhunter's Avatar
 
Join Date: Apr 2003
Location: Unknown
Posts: 2,812
Maybe replace DeGrainMedian and C3D with a single instance of Deen... :\

Btw, I think its better to place the temporal denoisers before the spatial ones !!!


Bye
__________________

Visit my IRC channel
Soulhunter is offline   Reply With Quote
Old 15th March 2005, 10:46   #10  |  Link
Didée
Registered User
 
Join Date: Apr 2002
Location: Germany
Posts: 5,390
Quote:
Originally posted by Soulhunter
Btw, I think its better to place the temporal denoisers before the spatial ones !!!
It depends. I mostly tend to use some spatial cleaning as preprocessing for temporal processing.

temporal first -> noise is "huge", low limits for the temporal filter won't catch all noise ("cutoff"-effect), high limits will remove the noise but cause damage, too.

spatial first, then temporal -> noise has "softened down", and the temporal filter has a much better chance to do good work with lower limits.

However it's dangerous to make a general statement about this. It absolutely depends on the charecteristics of source/detail and noise.
__________________
- We´re at the beginning of the end of mankind´s childhood -

My little flickr gallery. (Yes indeed, I do have hobbies other than digital video!)
Didée is offline   Reply With Quote
Old 15th March 2005, 12:38   #11  |  Link
Soulhunter
Bored...
 
Soulhunter's Avatar
 
Join Date: Apr 2003
Location: Unknown
Posts: 2,812
Yeah, I know it depends one the source etc...

But this statement refers to the script Chainmax posted !!!

Maybe have another look at the 1st. filter Chainmax used... I guess temporal denoisers have problems to "catch" the noise after it was smoothed by something like sshq, no? So, my suggestion was more like... Calm the noise down via temporal denoising and then do the final smoothing with sshq !!! EDIT: Doh, just realize that Chainmax used ssiq and not sshiq... ^^


Bye
__________________

Visit my IRC channel

Last edited by Soulhunter; 15th March 2005 at 15:08.
Soulhunter is offline   Reply With Quote
Old 15th March 2005, 15:03   #12  |  Link
Guest
Guest
 
Join Date: Jan 2002
Posts: 21,924
Quote:
Originally posted by Chainmax
I would appreciate it if you could download the encode, ask for some frames from the source and discuss this in a more informative way.
If you can't accept the answers, don't ask the questions (forum rule 12).
Guest is offline   Reply With Quote
Old 15th March 2005, 15:05   #13  |  Link
Leo 69
Registered User
 
Join Date: Nov 2004
Posts: 227
When processing VHS I prefer using something like :
----------------
Cnr2()
RemoveDirt()
FFT3DFilter(sigma=5) or
VagueDenoiser(threshold=2.5,method=1,nsteps=8,chromaT=0.9,wiener=true)
LimitedSharpen(ss_x=1.5,ss_y=1.5,Strength=100,wide=true,special=true)
----------------

and details are okay

Last edited by Leo 69; 15th March 2005 at 15:08.
Leo 69 is offline   Reply With Quote
Old 15th March 2005, 16:26   #14  |  Link
Chainmax
Huh?
 
Chainmax's Avatar
 
Join Date: Sep 2003
Location: Uruguay
Posts: 3,103
Quote:
Originally posted by neuron2
If you can't accept the answers, don't ask the questions (forum rule 12).
You sure seem confrontational today . If you carefully read my first reply, you'll see that the mayority of it consisted on an explanation as to why most filters in the chain were there. Only at the end of the first paragraph I adressed the nature or your answer and didn't even say that it was useless (even though it largely was), just that it didn't help me solve my problem, so rule 12 right back at you.

ChronoCross: unless I mistook what you said, I must clarify that the 16MB clip that can be downloaded from the OP is the final filtered encode so it doesn't need any extra filtering. What I need help in is how to solve the loss of tiny details (like the dimming of the stars in frame 189 or the disappearance of nightcrawler's eyes in frame 256) via eliminating/replacing some of the filters in the chain because other than that the clip looks perfect to me. Then again, I would certainly appreciate your comments on the quality of the encode or suggestions for alternate filters like Soulhunter and Leo 69 did.

Soulhunter: the first version of the clip was made with the following script:

SSIQ(diameter=11,strength=50,interlaced=false)
ConvertToYV12()
hqdn3d(0,0,3,3)
BlindDeHalo3(lodamp=4.0, hidamp=4.0,PPmode=2)
RemoveGrain()
Deen()
LimitedSharpen(ss_x=2,ss_y=2,Strength=160)
FastLineDarken()


and IMO it looked much worse. I can upload it too if you want to check it out.

Leo 69: I tried VagueDenoise and didn't like it much, and IIRC RemoveDirt is known for having trouble with fine lines. I will try out replacing DeGrainMedian and C3D with FFT3DFilter though, thanks for the suggestion .

Last edited by Chainmax; 15th March 2005 at 16:29.
Chainmax is offline   Reply With Quote
Old 15th March 2005, 16:33   #15  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Hollola, Finland
Posts: 4,324
Have you tried Didée's LRemoveDust? You might try substituting some of the stronger filters with that one, maybe DeGrainMedian+Con3D. It can be found in the RemoveGrain thread, second or third page from the end.

I belong to those who think that less filtering is better, especially with VHS sources where you can easily remove all the details there's left
__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...
Boulder is offline   Reply With Quote
Old 15th March 2005, 16:46   #16  |  Link
Chainmax
Huh?
 
Chainmax's Avatar
 
Join Date: Sep 2003
Location: Uruguay
Posts: 3,103
I'll try that as well, thanks for the suggestion. Like I said in my first reply, I am not one to usually indulge in filter gorging either. Is this the function you're referring to:

function LRemoveDust(clip input, int _mode, int "limit")
{
limit = default(limit,4)
LL = string(limit)
STR = "x "+LL+" + y < y "+LL+" - x "+LL+" - y > y "+LL+" + x ? ?"
repmode = 2
clensed = Clense(input)
rep = Repair(clensed, input, mode=repmode)
rg = RemoveGrain(rep, mode=_mode)
trep = TemporalRepair(rg, rep)
trep2 = isyuy2(input)
\ ? trep.converttoyv12()
\ : trep
input2 = isyuy2(input)
\ ? input.converttoyv12()
\ : input
limit!=0 ? yv12lutxy(trep2,input2,yexpr=STR,U=2,V=2) : last
out = isyuy2(input)
\ ? last.converttoyuy2().mergechroma(trep)
\ : last
return out
}


? Does it only need MaskTools?
Chainmax is offline   Reply With Quote
Old 15th March 2005, 17:20   #17  |  Link
Didée
Registered User
 
Join Date: Apr 2002
Location: Germany
Posts: 5,390
Quote:
Originally posted by Boulder
Have you tried Didée's LRemoveDust?
I was about to suggest that one. However, credits for the filter/script should really go to kassandro - I just added that bit of limiting thingie

Apart from the speed, the nice thing is that in case of a less noisy clip, the noise can be removed more or less completely - and in case of bigger noise, when LRemoveDust turns out to kill too much detail when trying to achieve full noise removal (with a big limit), it still does a very good job in "taming down" the noise (with lower limits), so that life for upfollowing filters gets much easier.

"My" version LRemoveDust indeed needs the MaskTools (as the majority of my scripts do ). However, in the RemoveGrain thread, kassandro posted a newer version (together with some "inofficial" plugins), that does all the work by plugins only: no MaskTools needed for that one, and it's even a tad faster.
__________________
- We´re at the beginning of the end of mankind´s childhood -

My little flickr gallery. (Yes indeed, I do have hobbies other than digital video!)
Didée is offline   Reply With Quote
Old 15th March 2005, 17:36   #18  |  Link
Chainmax
Huh?
 
Chainmax's Avatar
 
Join Date: Sep 2003
Location: Uruguay
Posts: 3,103
Are you referring to this function:

function MCRemoveDust(clip input, int _smooth, bool _grey)
{
repmode = 2
clmode = 4
quad = Quadruple(input, grey=_grey) # each pixel is quadrupled, SSETools are needed
qpel = RemoveGrain(quad, mode=12, modeU=-1) # blur the luma for searching motion vectors
bvectors = MVAnalyse(qpel, blksize=16, lambda=200, isb=true)
fvectors = MVAnalyse(qpel, blksize=16, lambda=200, isb=false)
backward = MVCompensate(quad, bvectors, mode=1)
forward = MVCompensate(quad, fvectors, mode=1)
clensed = mcclense(quad, backward, forward, grey=_grey).shrinkby2(grey=_grey) #SSETools are needed for shrinking
rep=Repair(clensed, input, mode=repmode, modeU=_grey ? -1 : repmode)
rg = RemoveGrain(rep, mode=clmode, modeU=_grey ? -1 : clmode)
return TemporalRepair(rg, rep, grey=_grey, smooth=_smooth)
}


? It needs MVTools and RemoveGrain at least...
Chainmax is offline   Reply With Quote
Old 15th March 2005, 17:56   #19  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Hollola, Finland
Posts: 4,324
No, there's
Code:
function LRemoveDust(clip input, int _mode, int "limit")
{
limit=default(limit,4)
repmode = 2
clensed = Clense(input)
rep=Repair(clensed, input, mode=repmode)
rg = RemoveGrain(rep, mode=_mode)
rd=TemporalRepair(rg, rep)
return LimitChange(rd, input, limit, limitU=255)
}
which needs the inofficial plugins. There's a download link in one of kassandro's posts over there. He also posted a chroma-limiting LRemoveDust.

Yep, credits also to kassandro for RemoveGrain, Clense, (Temporal)Repair and LimitChange
__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...

Last edited by Boulder; 15th March 2005 at 18:00.
Boulder is offline   Reply With Quote
Old 15th March 2005, 18:18   #20  |  Link
Chainmax
Huh?
 
Chainmax's Avatar
 
Join Date: Sep 2003
Location: Uruguay
Posts: 3,103
Ok, the fourth try is on the works, with chroma-limiting LRemoveDust to substitute Undot+DeGrainMedian+C3D and without aWarpSharp (gonna give FastLineDarken,s thinning another go), thanks for all the suggestiosn so far people .
Chainmax 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 15:27.


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