Avisynth: Wavelet Noise Reduction?
I've been playing since yesterday with a filter that's floating around the net, which there is no English documentation. Here's the filter: www.kvcd.net/wnr.zip
It's a VirtualDub filter, but it can be made to work with AviSynth. The quality is just amazing, but it's SLOW and I mean SLOOOOWWWW. But here it is so you can try it, and see for yourself the quality gained and file size dropped: Just add these lines to your script: Code:
# Include the following line where you normally load your plugins. -kwag |
Let's start the fun :mrgreen:
This will apply wavelet noise reduction ONLY where temporalsoften is being applied. Code:
ScriptClip("nf = YDifferenceToNext()"+chr(13)+ "nf >= 2 ? \ The values 7710, 7454, 7710 are experimental :!: Have fun ;) -kwag |
Corrected to this:
ConvertToRGB().VD_wnr( 20, 20, 20, 0, 0, 0, 0, 0, 0) Code:
ScriptClip("nf = YDifferenceToNext()"+chr(13)+ "nf >= 2 ? \ |
Re: Wavelet Noise Reduction
Quote:
|
This filter doesn't work correctly in a dynamic adaptive nature :!:
It was fun to test, but the current adaptive script filter combination just beats the crap out of it :mrgreen: Bye Bye WNR :!: Edit: Using it alone as a static filter, it does work, but after comparing clips with the current script, the file size is way smaller with the current script WITHOUT the WNR filter. -kwag |
I have no idea if this is anything even slightly similar:
VagueDenoiser 0.11: Wavelet based denoiser. But you might give it a whirl. |
Thanks sh0dan,
Apparently it is :!: I just can't get the thing to work. It calls for two parameters, but I get "Invalid argument to function "VagueDenoiser" when I try to open it in Vdub. Time to look at the source 8) -kwag |
Yeah I cann't get to work either :!: :?
|
Ok, I got it working. I had the .dll in the plugins directory of AviSynth, and I guess autoload didn't work correctly.
I specified the hard path, and now it works. LoadPlugin("C:\Filters25\VagueDenoiser.dll") as usual, and then VagueDenoiser(0.8, 2) after the source line ( that's where I'm testing ). -kwag |
Well, here are the results. The filter is SUPERB :!: Look at the file size drop on the 9 second clip 8O
But now we need a 10Ghz computer to encode :mrgreen: Here are the benchmarks and samples: Current adaptive script ONLY: http://www.kvcd.net/nonr.mpg Encode time: 23s. Clip size: 9 seconds. File size: 1,083KB Current adaptive script+wavelet noise filter VagueDenoiser(0.8, 1): http://www.kvcd.net/nr1.mpg Encode time: 1m:59s. Clip size: 9 seconds. File size: 1,053KB Current adaptive script+wavelet noise filter VagueDenoiser(0.8, 2): http://www.kvcd.net/nr2.mpg Encode time: 1m:44s. Clip size: 9 seconds. File size: 1,055KB -kwag |
Quote:
I'd love to try this out on a full movie since I'm gonna be out of town until tomorrow evening. :D |
Quote:
Right after your source line, before resizing. You can try it after resizing too. I haven't yet :!: Edit: Works like a charm AFTER GripSize :!: Time dropped to 1m:5s :mrgreen: -kwag |
Anyone who wants to try the script, here it is:
Code:
## DLL Section ## |
And for using the wavelet filter only on the adaptive part of the script, use this:
Code:
ScriptClip("nf = YDifferenceToNext()"+chr(13)+ "nf >= 2 ? \ Remember to remove the VagueDenoiser(0.8,2) on the top of your script after GripSize ;) Edit: The last parameter of VagueDenoiser (Type of wavelet) must be 0 or 1. From the docs: "Two types of wavelets are used here: -Symmlet8: Daniel Lemire algorithm (use wavelet=0) -Daubechies4: Ian Kaplan algorithm (use wavelet=1)" So use 0 or 1. Not 2 as I had tested :!: -kwag |
Here's a sample with adaptive wavelet filter in full action.
You'll see the value of "nf" on the top of the screen, and remember that when the value is greater or equal to 2, the wavelet and temporal filters are not operational. Only on values below 2 is that the temporal and the wavelet filters are functioning. I used wavelet type 1 (Ian Kaplan algorithm), because the sample size was 1KB smaller that with type 0 (Daniel Lemire algorithm) http://www.kvcd.net/adaptive-vague-1.mpg Happy testing ;), -kwag |
@ Kwag..
sheesh.. gimmie a chance to D/L your first sample :) Edit: just got fist clip. Looks great here. Now on to others.. I'll give your latest scrip-snip a go shortly. Thanks for the newbie items. -vhelp |
Kwag..
What class does that Filter fall under ?? Color space: * YUV, YV12 AVIsynth: * v2.52, v2.50 or older v2x So that I can plut in its right place, where I keep my DLL's ie, * \dlls\.. for old v2x, and * \dlls252\.. for latest YV12 and AVIsynth v2.52 Tanks, -vhelp |
From the docs:
"Required: Avisynth 2.52 YV12 colorspace" -kwag |
Quote:
and tried the above, VagueDenoiser(0.8,1) either .13 has a memory leak, or gremlins are hard at work my systems page file kept growing and growing and growing... it got up to like 4Gigs and my system ran out of memory if i dont put it in the adaptive section, then my system only uses 250Mb of page file, and it works fine so maybe it isnt the gremlins just figured i would pass this along -phibertron |
Yes, I agree.
Definate "memory leak". I got to the point where my system crashed in one instance, and while another, I got a warning that my HD was filled and to close apps and things. naturally, I stop TMPG's encoding. This was only based on a 1 minute clip I was test encoding (which took approx. 5 minutes to complete) But I am noticing something in the final quality sage. "chizels" on solid scenes where you can see "hatches" or "blocks" float around. I'm still debuggin this, as it's still to "bright" in my workroom - - its ben sunny all day here. Its harder to judge w/ too much sun is shining hehe.. -vhelp |
.
. VagueDenoiser... I think that this filter might actually be better suited for VHS captures.. only because the "chizels" remind me of VHS encodes. I could be wrong, but only way to know for sure is to try it out on VHS capture, and I'm not at that point just yet. Maybe later or so. EDIT: Yes, either that (the "chizel" effect) or it has a bad color-space conversion, because I do notice a slight difference in color output. -vhelp |
Quote:
I just had to stop an encode, and when I looked at the memory usage inTMPEG, it was almost 500MB 8O It probably has to do with memory allocation/release every time the filter switches on and off. So I guess it's another one of those filters we can't use dynamically :? So it goes back right after the GripSize again :!: -kwag |
@kwag
Why not try the ne filter on the script challenge? That is worse than a VHS capture, perhaps it would do wonders. |
Quote:
-kwag |
i don't test it at the moment,more hints and results are welcome.
new VagueDenoiser: http://forum.doom9.org/showthread.php?s=&threadid=56871 :wink: |
Quote:
-kwag |
Quote:
|
Quote:
-kwag |
Personally, I think that your older example was better. Because it was moe detailed ...
|
It's probably result of the wavelet noise filter. I just threw that in there to see how it would look, as it was requested here. I't s really a SLOWWWW filter, but I think that with correct parameters, it can do an awesome job. But then, we need CPUMuscle to encode with that filter :)
Hopefully it will be further optimized :!: -kwag |
Here is my opinion, I have compared PixieDust vs. VagueDenoiser filters. I had both filters added to the optimal script, but nothing else so there identical but Pixie of course has to convert to YuY2 then to YV12 after the filter. Well I encoded a 53 second TV capture clip with resolution of 640x480 put into 544x480 (yes I know that is a lot for a standard coaxial cable service (non-digital)). But the results were amazing PixieDust was only 4.74 MB and VagueDenoiser was 5.89 MB and the picture quality look almost the same, but I am no expert (like kwag). Also to not they were about the same time to encode, but PixieDust was a little faster. I think someone should test those 2 filters because I need a second opinion.
|
Hi ak47,
How about FaeryDust() or even GoldDust(), which are the strongest of the Dust series :?: -kwag |
Well if anybody cares VagueDenoiser is up to version 0.2 8O , this is probably the most updated filter this days :mrgreen: to bad that my Puter don't like rar files. :roll:
|
Quote:
|
Here are the results its TV capture anime that captured at 640x480 and i encode it with gop of 18 with gop of 18. This clip is 1:21.
Code:
## DLL Section ## |
The filter is SOOOOO SLOOOOWWWWW it hurts :!:
I'll put Vague in a wine barrel, and let it ripe just like a bottle of wine :!: Maybe in a year or so it will be useable. Right now, the Dust series does just as good. I'm done with Vague until I see a speed increase and a quality superiority over the current script and filter chain :cool: -kwag |
"Another one can't bite the dust."
Sorry I had to do it; it was a rearrange quote from Queen. |
You mean "Another one bites the dust" :mrgreen:
-kwag |
Ya but since dust won I had put in can't in it (that what I meant when I said "rearrange"). Yes I know added is a better word then rearrange, but you get the point.
|
Got you now :mrgreen:
|
Site design, images and content © 2002-2024 The Digital FAQ, www.digitalFAQ.com
Forum Software by vBulletin · Copyright © 2024 Jelsoft Enterprises Ltd.