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 Development

Reply
 
Thread Tools Search this Thread Display Modes
Old 7th May 2017, 01:21   #1181  |  Link
BakaProxy
Registered User
 
Join Date: Jan 2015
Posts: 47
@Khanatila, I think I found a(n edge case) bug.
http://screenshotcomparison.com/comparison/209076
(If it's not obvious, check the black smudge at the top.)
This happens with bigger a values (9 on this example on a 480p clip) and If I recall correctly knlmeanscl internally pads the video clip, so I think that this is just the black padding leaking into the image. (if so, maybe you could mirror instead?)
Though this is just my hypothesis, feel free and I'd love you to prove me wrong.

As for the data on this specific scenario they're in the screenshot using info=true, if more is necessary I'm ready to provide such.
BakaProxy is offline   Reply With Quote
Old 12th May 2017, 23:01   #1182  |  Link
Logan9778
Registered User
 
Join Date: Mar 2017
Posts: 118
Hey guys, I'm new to all this GitHub stuff. How would you compile the code for KNLMeansCL to get the .dll file in Windows 10 ( I use AviSynth )?
Logan9778 is offline   Reply With Quote
Old 12th May 2017, 23:17   #1183  |  Link
Groucho2004
 
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
Quote:
Originally Posted by Logan9778 View Post
Hey guys, I'm new to all this GitHub stuff. How would you compile the code for KNLMeansCL to get the .dll file in Windows 10 ( I use AviSynth )?
Why do you feel the need to compile it if there are perfectly adequate releases?
__________________
Groucho's Avisynth Stuff

Last edited by Groucho2004; 13th May 2017 at 00:34.
Groucho2004 is offline   Reply With Quote
Old 12th May 2017, 23:36   #1184  |  Link
Khanattila
Registered User
 
Khanattila's Avatar
 
Join Date: Nov 2014
Posts: 440
Quote:
Originally Posted by dipje View Post
@Khanattila:

A bit off topic, but on your Github I see an old project KPassFilterCL. Do I see correctly that it's Avisynth only? I tried using it in Vapoursynth through the core.avs.LoadPlugin stuff, and it appears to be working. I use fmtconv routines to convert 16bit Vapoursynth to avisynth's "stacked" format, then use the routines from KPassFilterCL with their 'lsb_inout' set to True. This works OK (I guess) for 'mode = magnitude' but seems to only produce black output when 'mode = phase' ? If I switch to 8bit I do suddenly get output.

Can you explain a bit of it? I'm trying to separate an image into multiple images based on frequeny content (or wavelets maybe?), to apply different filtering to different frequency-ranges and then merge it all back into a single image. KPassFilterCL seems to be made for that but I'm not sure if that's going to work or if I'm using it wrong.

With the 'low pass' routine I'm trying to get, well, only low-frequency content, which I expect to be a very blurry picture (I'm talking about a grayscale luminance only clip BTW), but in brightness / contrast / levels to be pretty much the same as the starting image.
But I only seem to get very dark output, when I change the 'cutoff' parameter the image starts to look more like the original in brightness / contrast, but also less blurry, so more high-freq content is getting in .

Is it normal that the cutoff parameter seems to require very high values (as in over 250000.0) to do something?

And if I would want to split an image into three parts, very blurry parts (almost no details, low-frequency), course details (mid-frequency) and small (micro) details (high frequency) can I do that with this plug? If so, could you give an example?
Sorry if I did not answer you first but that filter was born almost for fun and I never optimized or improved its effectiveness.
If you really want to use it for something I have to check it for a moment, because I really do not remember what all the functions do.
__________________
github.com
Khanattila is offline   Reply With Quote
Old 12th May 2017, 23:40   #1185  |  Link
Khanattila
Registered User
 
Khanattila's Avatar
 
Join Date: Nov 2014
Posts: 440
Quote:
Originally Posted by BakaProxy View Post
@Khanatila, I think I found a(n edge case) bug.
http://screenshotcomparison.com/comparison/209076
(If it's not obvious, check the black smudge at the top.)
This happens with bigger a values (9 on this example on a 480p clip) and If I recall correctly knlmeanscl internally pads the video clip, so I think that this is just the black padding leaking into the image. (if so, maybe you could mirror instead?)
Though this is just my hypothesis, feel free and I'd love you to prove me wrong.

As for the data on this specific scenario they're in the screenshot using info=true, if more is necessary I'm ready to provide such.
Ok, this is bug maybe. I have to check. Or maybe I did it, since the version you use is old.
__________________
github.com
Khanattila is offline   Reply With Quote
Old 13th May 2017, 00:21   #1186  |  Link
Logan9778
Registered User
 
Join Date: Mar 2017
Posts: 118
Quote:
Originally Posted by Groucho2004 View Post
Why do you feel the need to compile it if there are a perfectly adequate releases?
Ahh, thanks, I didn't see the zip had the .dll inside it.
Logan9778 is offline   Reply With Quote
Old 27th May 2017, 16:48   #1187  |  Link
MysteryX
Soul Architect
 
MysteryX's Avatar
 
Join Date: Apr 2014
Posts: 2,559
Quote:
Originally Posted by MysteryX View Post
With this simple code, it produces random results and mixes frames together. I can't believe I went to long without realizing it.

It fails when running as MT_SERIALIZED. The only MT mode that works is MT_MULTI_INSTANCE -- which isn't ideal for this type of filter.
For the records, this is probably due to this bug in Avisynth+ with MT_SERIALIZE
https://forum.doom9.org/showthread.p...03#post1807903
MysteryX is offline   Reply With Quote
Old 9th June 2017, 00:03   #1188  |  Link
MysteryX
Soul Architect
 
MysteryX's Avatar
 
Join Date: Apr 2014
Posts: 2,559
This doesn't work in 16-bit

Code:
ConvertToYV24()
ConvertBits(16)
KNLMeansCL(D=2, A=2, h=1.5, channels="YUV")
KNLMeansCL: 'channels = YUV' require a YV24 pixel format!
MysteryX is offline   Reply With Quote
Old 13th June 2017, 17:54   #1189  |  Link
Khanattila
Registered User
 
Khanattila's Avatar
 
Join Date: Nov 2014
Posts: 440
Quote:
Originally Posted by MysteryX View Post
This doesn't work in 16-bit

Code:
ConvertToYV24()
ConvertBits(16)
KNLMeansCL(D=2, A=2, h=1.5, channels="YUV")
KNLMeansCL: 'channels = YUV' require a YV24 pixel format!
I am very busy so I do not have time now, but I notice your reports
__________________
github.com
Khanattila is offline   Reply With Quote
Old 17th June 2017, 06:52   #1190  |  Link
goorawin
Registered User
 
Join Date: Feb 2012
Posts: 82
KNLMeansCL 64bit suddenly not loading

I have been using KNLMeansCL 64bit for sometime without problems on windows10 pro with a GeForce GTX 650 graphics card.
Now after some major windows updates, it no longer works in 64 bit. It will not load the plugin and comes up with the error “there is no function named KNLMeansCL”. I have tried a number of versions of KNLMeansCL (including v1.1.0) but all have the same problem. All other 64bit plugin work as they should. Even xnlmeans works which I assume is not much different to KNLMeansCL except for GPU usage.
Interestingly the32 bit version of KNLMeansCL works just fine, so what's the difference?.
The other interesting thing is that, on another windows 10 pro computer with an on board Intel HD Graphics 630 card which has also had the same updates, everything work as it should in 64bit.
So what are the dependencies of KNLMeansCL in 64bit?
Any help would be appreciated.
goorawin is offline   Reply With Quote
Old 17th June 2017, 08:25   #1191  |  Link
Groucho2004
 
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
Quote:
Originally Posted by goorawin View Post
So what are the dependencies of KNLMeansCL in 64bit?
Run AVSMeter64 with the switch "-avsinfo", it will report any missing dependencies.
Groucho2004 is offline   Reply With Quote
Old 18th June 2017, 01:00   #1192  |  Link
goorawin
Registered User
 
Join Date: Feb 2012
Posts: 82
Quote:
Originally Posted by HolyWu View Post
From my experence reinstalling GeForce driver after Win10 major updates solves this issue. YMMV.
That did the trick thank you. Interesting that it only caused an issue with 64bit scripts.
goorawin is offline   Reply With Quote
Old 30th June 2017, 19:14   #1193  |  Link
SaurusX
Registered User
 
Join Date: Feb 2017
Posts: 134
Great filter, khanatilla. Non-local means is an excellent noise reduction theory and with OpenCL its actually usable in my computer. Thanks for your hard work!
SaurusX is offline   Reply With Quote
Old 25th July 2017, 15:51   #1194  |  Link
SaurusX
Registered User
 
Join Date: Feb 2017
Posts: 134
Well, I found a way to break the filter while encoding some cartoons. Here's the pseudo-script:

MPEG2SOURCE("myclip")
TComb(mode=0, blah, blah) #for dot-crawl removal
TFM()
TDecimate()
the masked and motion-compensating derainbowing procedure found here
Bifrost(interlaced=false) #1.1 version for final de-rainbowing
KNLMeansCL(d=2,a=3,h=1.2,device_type="GPU") #Using Intel HD4000 graphics
maa2() #anti-alias
msharpen() #resharpen
dehalo_alpha() #de-halo
awarpsharp2() #sharpen chroma

It seems like too much temporal analysis will cause mask pops, frame flashing, and mistimed chroma in the final encode. I can remove TComb or remove Bifrost or change the d parameter to 1 and the problems disappear. This may not be a specific problem to KNLMeansCL, but I thought you'd like to know about it.

Last edited by SaurusX; 25th July 2017 at 15:54.
SaurusX is offline   Reply With Quote
Old 1st August 2017, 18:22   #1195  |  Link
MysteryX
Soul Architect
 
MysteryX's Avatar
 
Join Date: Apr 2014
Posts: 2,559
Quote:
Originally Posted by MysteryX View Post
This doesn't work in 16-bit

Code:
ConvertToYV24()
ConvertBits(16)
KNLMeansCL(D=2, A=2, h=1.5, channels="YUV")
KNLMeansCL: 'channels = YUV' require a YV24 pixel format!
Quote:
Originally Posted by Khanattila View Post
I am very busy so I do not have time now, but I notice your reports
This one is an easy bug, any plans to fix it soon?
MysteryX is offline   Reply With Quote
Old 10th August 2017, 12:39   #1196  |  Link
tuanden0
Registered User
 
Join Date: Oct 2016
Posts: 111
Sorry Sir, but after update my VGA card driver, the KNLMeansCL fillter make my PC reboot because the GPU load over 100%.
I tried to reinstall old driver but the issue still there.
I'm using NVIDIA GeForce GTX 650Ti.
tuanden0 is offline   Reply With Quote
Old 24th August 2017, 18:32   #1197  |  Link
Ben_Nicholls
Registered User
 
Join Date: Aug 2017
Location: N/A
Posts: 12
Quote:
Originally Posted by tuanden0 View Post
Sorry Sir, but after update my VGA card driver, the KNLMeansCL fillter make my PC reboot because the GPU load over 100%.
I tried to reinstall old driver but the issue still there.
I'm using NVIDIA GeForce GTX 650Ti.
Have you confirmed that your GPU is 100% stable?

Running MSI Kombustor or FurMark should let you know: if either one crashes, your GPU isn't stable and probably needs replacing.
Ben_Nicholls is offline   Reply With Quote
Old 27th August 2017, 10:45   #1198  |  Link
tuanden0
Registered User
 
Join Date: Oct 2016
Posts: 111
Quote:
Originally Posted by Ben_Nicholls View Post
Have you confirmed that your GPU is 100% stable?

Running MSI Kombustor or FurMark should let you know: if either one crashes, your GPU isn't stable and probably needs replacing.
Thank for your reply,
My problem solved, my VGA card is dirty, so they crashed because it's too hot
I cleaned my VGA so it's OK
tuanden0 is offline   Reply With Quote
Old 27th August 2017, 18:21   #1199  |  Link
MysteryX
Soul Architect
 
MysteryX's Avatar
 
Join Date: Apr 2014
Posts: 2,559
Quote:
Originally Posted by tuanden0 View Post
Thank for your reply,
My problem solved, my VGA card is dirty, so they crashed because it's too hot
I cleaned my VGA so it's OK
Just cleaned my laptop too. Removing dust fixes a few things
MysteryX is offline   Reply With Quote
Old 18th September 2017, 10:34   #1200  |  Link
Khanattila
Registered User
 
Khanattila's Avatar
 
Join Date: Nov 2014
Posts: 440
Quote:
Originally Posted by bcn_246 View Post
Roughly what does NLMeansCL2(h=radius*1.5,u=3,v=3) convert to for KNLMeansCL()?
KNLMeansCL(d=0), but the results are different.
NLMeansCL2 worked on a smaller image.
__________________
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 13:18.


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