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 12th December 2015, 10:01   #1  |  Link
martin53
Registered User
 
Join Date: Mar 2007
Posts: 407
xNLMeans

EDIT 03/24/2016: v0.03 - bugfixes & multiscale fingerprints

New Non-Local-Means denoiser plugin xNLMeans v0.03

Comments welcome

please see manual for details

needs Visual C++ Redistributable Package for Visual Studio 2015 Update 1 (please check for more recent versions, link may be outdated)

Last edited by martin53; 30th March 2016 at 13:05. Reason: Changed link to Redistributable Update 1
martin53 is offline   Reply With Quote
Old 12th December 2015, 11:44   #2  |  Link
~ VEGETA ~
The cult of personality
 
~ VEGETA ~'s Avatar
 
Join Date: May 2013
Location: Planet Vegeta
Posts: 155
so can I use it on a computer that doesn't have a GPU?
~ VEGETA ~ is offline   Reply With Quote
Old 12th December 2015, 15:07   #3  |  Link
Groucho2004
 
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
Quote:
Originally Posted by ~ VEGETA ~ View Post
so can I use it on a computer that doesn't have a GPU?
Yes, but it may be difficult to check if it's working since you can't connect a monitor to a computer without GPU.
Groucho2004 is offline   Reply With Quote
Old 12th December 2015, 16:13   #4  |  Link
feisty2
I'm Siri
 
feisty2's Avatar
 
Join Date: Oct 2012
Location: void
Posts: 2,633
which version of msvcr do I need to run this?
feisty2 is offline   Reply With Quote
Old 12th December 2015, 16:40   #5  |  Link
martin53
Registered User
 
Join Date: Mar 2007
Posts: 407
Quote:
Originally Posted by feisty2 View Post
which version of msvcr do i need to run this?
msvcr 2015
martin53 is offline   Reply With Quote
Old 13th December 2015, 16:56   #6  |  Link
Khanattila
Registered User
 
Khanattila's Avatar
 
Join Date: Nov 2014
Posts: 440
I read the documentation to find some interesting innovations. I have not found it.
__________________
github.com
Khanattila is offline   Reply With Quote
Old 13th December 2015, 17:43   #7  |  Link
Mounir
Registered User
 
Join Date: Nov 2006
Posts: 773
LoadPlugin unable to load xNLMeans.dll module not found.
That's what i get what do i miss ?
Mounir is offline   Reply With Quote
Old 13th December 2015, 18:23   #8  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
@Mounir, looks like you may have missed posts #4 and #5.
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???
StainlessS is offline   Reply With Quote
Old 13th December 2015, 21:16   #9  |  Link
Mounir
Registered User
 
Join Date: Nov 2006
Posts: 773
Okay, where can i get this "msvcr 2015"
Mounir is offline   Reply With Quote
Old 13th December 2015, 21:19   #10  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
All In One Installer (installs all runtimes), http://www.wincert.net/forum/topic/9...utable-x86x64/

If problems, then see several posts from here:- http://forum.doom9.org/showthread.ph...04#post1749404
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???
StainlessS is offline   Reply With Quote
Old 14th December 2015, 16:46   #11  |  Link
martin53
Registered User
 
Join Date: Mar 2007
Posts: 407
Quote:
Originally Posted by rean View Post
Why not to compile it static?! It is just a few mouse clicks to change project settings...
http://forum.doom9.org/showthread.ph...05#post1746705
martin53 is offline   Reply With Quote
Old 14th December 2015, 17:06   #12  |  Link
martin53
Registered User
 
Join Date: Mar 2007
Posts: 407
Quote:
Originally Posted by Khanattila View Post
I read the documentation to find some interesting innovations. I have not found it.
Really???
  • sdev because the filter impulse response resembles the geometrical weight function. I did not find an sdev equivalent in kNLMeansCL, but be happy to test - if there is one, please give me a hint
  • wmin to adjust the blend effect between the true filter output and unfiltered input
  • vcomp to fight high amplitude compression artefacts
  • center to fight mosquito noise
martin53 is offline   Reply With Quote
Old 14th December 2015, 21:41   #13  |  Link
Groucho2004
 
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
Quote:
Originally Posted by rean View Post
OMG Users want your 10000 megabytes of unwanted stuff on PC because Groucho2004 love it...
I really tried but can't make sense of that sentence.
Groucho2004 is offline   Reply With Quote
Old 15th December 2015, 17:06   #14  |  Link
Khanattila
Registered User
 
Khanattila's Avatar
 
Join Date: Nov 2014
Posts: 440
Quote:
Originally Posted by martin53 View Post
Really???
  • sdev because the filter impulse response resembles the geometrical weight function. I did not find an sdev equivalent in kNLMeansCL, but be happy to test - if there is one, please give me a hint
  • wmin to adjust the blend effect between the true filter output and unfiltered input
  • vcomp to fight high amplitude compression artefacts
  • center to fight mosquito noise
Although it was present in the original Non-local means paper I deliberately ignored the Gaussian distribution (sdev). Because it was not shown that brings benefits.

In my implementation wmin and center are equal to 1. Which it is also the situation recommended and more used. I do not think that it is interesting to allow users to modify this parameter.

Variance Compensation in fact is new. But I do not know how useful. Non-local means is designed to Gaussian noise and may not be effective.
__________________
github.com
Khanattila is offline   Reply With Quote
Old 15th December 2015, 17:39   #15  |  Link
Groucho2004
 
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
Quote:
Originally Posted by rean View Post
OMG Users want your 10000 megabytes of unwanted stuff on PC because Groucho2004 love it...
Quote:
Originally Posted by Groucho2004 View Post
I really tried but can't make sense of that sentence.
Hm, you may be referring to the space this runtime installer occupies on the user's hard drive. It's not quite 10000 megabytes, it's actually 75MB on a 32 Bit system and 135MB on a 64 Bit system, slightly less than your estimation.
Groucho2004 is offline   Reply With Quote
Old 15th December 2015, 18:21   #16  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
And of course more than Avisynth will use all of the runtimes, so are more than likely necessary (sooner or later) anyway.
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???
StainlessS is offline   Reply With Quote
Old 15th December 2015, 19:22   #17  |  Link
martin53
Registered User
 
Join Date: Mar 2007
Posts: 407
Quote:
Originally Posted by Khanattila View Post
Although it was present in the original Non-local means paper I deliberately ignored the Gaussian distribution (sdev). Because it was not shown that brings benefits.

In my implementation wmin and center are equal to 1. Which it is also the situation recommended and more used. I do not think that it is interesting to allow users to modify this parameter.

Variance Compensation in fact is new. But I do not know how useful. Non-local means is designed to Gaussian noise and may not be effective.
Hi,
it is interesting that you could show that sdev brings no benefits. Does kNLMeansCL use any geometrical weighting, or are all pixels in the s range weighted same? I mainly used a digicam church indoor scene for my visual comparisons because it is blurry and noisy. The difference between original and denoised clip shows large and significant spots when higher s is used (or when sdev is >>1 with xNLMeans). I reason that large spots are not OK when the disturbance is expected to be independent between pixels, and I'm interested about more explanation from your side about this.

At the beginning, I observed that xNLMeans was unable to denoise pixels close to edges and generally in structured areas with low settings, while it blurred smooth areas with high settings. Because both the compressor will allow for more tolerance if there is more structure to compress, and (to my opinion) the eye is not aware of a bit more filtering of structures than smooth regions, I recommend the vcomp setting (or a better approach) as an extension to the controllers.

With center, I am unsure, too, about its general influence. When sdev is low, most of the total weight of a similarity neighborhood comes from the center pixel, which is illogical, looking at how the algorithm is justified. For this situation I recommend the control for the center pixel. When sdev is high or with a flat geometrical averaging, center should be unimportant.

And finally I feel that wmin might be the weakest point of the original paper itself. I never found a reason why the center pixel's weight should be so highly variable as to deliberately follow the weight of one of the other pixels. The whole thing looks to me like the paper didn't work first, and they needed no matter which solution but with attractive results - and voilą. Today we lack experience with this setting because all implementations strictly followed the paper, and I'm optimistic NLMeans can be a better remedy against not only gaussion noise but also artefacts with the additional controls.

But please don't take these explanations as a battle against kNLMeansCL. It's not meant like that! I just felt that I wanted more subtle control and programmed it, but I use kNLMeansCL for my movie clips, too Thanks for that great plugin btw!
martin53 is offline   Reply With Quote
Old 15th December 2015, 21:31   #18  |  Link
Khanattila
Registered User
 
Khanattila's Avatar
 
Join Date: Nov 2014
Posts: 440
Quote:
Originally Posted by martin53 View Post
Hi,
it is interesting that you could show that sdev brings no benefits. Does kNLMeansCL use any geometrical weighting, or are all pixels in the s range weighted same? I mainly used a digicam church indoor scene for my visual comparisons because it is blurry and noisy. The difference between original and denoised clip shows large and significant spots when higher s is used (or when sdev is >>1 with xNLMeans). I reason that large spots are not OK when the disturbance is expected to be independent between pixels, and I'm interested about more explanation from your side about this.

At the beginning, I observed that xNLMeans was unable to denoise pixels close to edges and generally in structured areas with low settings, while it blurred smooth areas with high settings. Because both the compressor will allow for more tolerance if there is more structure to compress, and (to my opinion) the eye is not aware of a bit more filtering of structures than smooth regions, I recommend the vcomp setting (or a better approach) as an extension to the controllers.

With center, I am unsure, too, about its general influence. When sdev is low, most of the total weight of a similarity neighborhood comes from the center pixel, which is illogical, looking at how the algorithm is justified. For this situation I recommend the control for the center pixel. When sdev is high or with a flat geometrical averaging, center should be unimportant.

And finally I feel that wmin might be the weakest point of the original paper itself. I never found a reason why the center pixel's weight should be so highly variable as to deliberately follow the weight of one of the other pixels. The whole thing looks to me like the paper didn't work first, and they needed no matter which solution but with attractive results - and voilą. Today we lack experience with this setting because all implementations strictly followed the paper, and I'm optimistic NLMeans can be a better remedy against not only gaussion noise but also artefacts with the additional controls.

But please don't take these explanations as a battle against kNLMeansCL. It's not meant like that! I just felt that I wanted more subtle control and programmed it, but I use kNLMeansCL for my movie clips, too Thanks for that great plugin btw!
Each innovation is welcome. I always try to improve it

When I compare two neighborhoods, S(p, s) and S(q, s), each pixel has the same weight.
__________________
github.com
Khanattila is offline   Reply With Quote
Old 16th December 2015, 13:55   #19  |  Link
feisty2
I'm Siri
 
feisty2's Avatar
 
Join Date: Oct 2012
Location: void
Posts: 2,633
so I tried vcomp and center to destroy compression artifacts and it looks pretty cool
well, I could still get a tiny little bit better result with some kind of "abused" knlmeanscl (without vcomp and center)
source:


Code:
xnlmeans(a=4,h=2.2,vcomp=0.5,center=0,s=1)


Code:
import vapoursynth as vs
import Placebo as pb
core = vs.get_core()

clp = xxx
clp = core.std.ShufflePlanes(clp, planes=0, colorfamily=vs.GRAY)
clp = core.fmtc.bitdepth(clp, fulls=False, fulld=True, bits=32, flt=True)

cln = pb.reconstructor(clp,nrlevel=1)

cln.set_output ()


Code:
import vapoursynth as vs
import Placebo as pb
core = vs.get_core()

clp = xxx
clp = core.std.ShufflePlanes(clp, planes=0, colorfamily=vs.GRAY)
clp = core.fmtc.bitdepth(clp, fulls=False, fulld=True, bits=32, flt=True)

cln = pb.reconstructor(clp,nrlevel=1)
cln = pb.halonr(cln)
cln = pb.generalnr(cln,clp,block_step=4)
vec = pb.getvectors(cln)
clp = pb.nrfinal(cln, core.std.MakeDiff(clp,cln), vec)

clp.set_output ()


vaporsynth stuff: https://github.com/IFeelBloated/Vapo...ter/Placebo.py

Last edited by feisty2; 16th December 2015 at 14:39.
feisty2 is offline   Reply With Quote
Old 21st December 2015, 18:11   #20  |  Link
Khanattila
Registered User
 
Khanattila's Avatar
 
Join Date: Nov 2014
Posts: 440
Quote:
Originally Posted by feisty2 View Post
so I tried vcomp and center to destroy compression artifacts and it looks pretty cool
well, I could still get a tiny little bit better result with some kind of "abused" knlmeanscl (without vcomp and center)
source:


Code:
xnlmeans(a=4,h=2.2,vcomp=0.5,center=0,s=1)


Code:
import vapoursynth as vs
import Placebo as pb
core = vs.get_core()

clp = xxx
clp = core.std.ShufflePlanes(clp, planes=0, colorfamily=vs.GRAY)
clp = core.fmtc.bitdepth(clp, fulls=False, fulld=True, bits=32, flt=True)

cln = pb.reconstructor(clp,nrlevel=1)

cln.set_output ()


Code:
import vapoursynth as vs
import Placebo as pb
core = vs.get_core()

clp = xxx
clp = core.std.ShufflePlanes(clp, planes=0, colorfamily=vs.GRAY)
clp = core.fmtc.bitdepth(clp, fulls=False, fulld=True, bits=32, flt=True)

cln = pb.reconstructor(clp,nrlevel=1)
cln = pb.halonr(cln)
cln = pb.generalnr(cln,clp,block_step=4)
vec = pb.getvectors(cln)
clp = pb.nrfinal(cln, core.std.MakeDiff(clp,cln), vec)

clp.set_output ()


vaporsynth stuff: https://github.com/IFeelBloated/Vapo...ter/Placebo.py
Better than I thought. I would try to do something similar.
__________________
github.com
Khanattila 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 04:19.


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