Log in

View Full Version : MCTemporalDenoise [v1.4.20 - Update 2010/07/02]


Pages : 1 2 3 4 5 6 7 [8] 9 10 11 12 13 14 15 16 17 18 19

Joachim Buambeki
17th May 2010, 00:01
Other people in the thread dedicated to Avisynth 64bit seem to use it without problems (http://forum.doom9.org/showthread.php?p=1393260&highlight=mctemporaldenoise#post1393260) (last posts that mentions it in the thread). Since I use no anime preset or the anti aliasing function of MCTemporalDenoise I do not understand why Sangnom is even called. That is why I am confused...:confused:
Also I checked the 64bit builds of different filters by JoshyD and squid and have not found a 64bit version of Sangnom.

Best Regards
David

Didée
17th May 2010, 00:04
Try explictely setting MCTemporalDenoise(setings="medium",useEEDI2=true).

Some filtering with SangNom is initiated within the function, but not used later on. Even though SangNom is not actually used with the given call, the parser has the need to evaluate the SangNom() filter.

Taken strictly, this is sign of unkosher scripting ... which, in same or similar style, I might have done "a thousand" times myself. :D


Edit - Clarification by example:

Assume this little quasi-script:

do_filter = false
use_filterX = false

vid = something

filter = use_filterX ? vid.filterX()
\ : vid.filterY()

out = do_filter ? filter : vid

return( out )

With given settings, neither filterX nor filterY are actually performed. The output result is just "vid".

However, by the time when the parser is parsing the "filter = ... ? .. : .." line, it needs to know "filterY", because it needs to fully evaluate the code line. The path given by "use_filterX=false" requires that the parser evaluates "filter = vid.filterY()". Albeit the action never is performed, it is still required that "filterY" is *known* at least.

Joachim Buambeki
17th May 2010, 00:14
Try explictely setting MCTemporalDenoise(setings="medium",useEEDI2=true).Thanks Didée, that seemed to be one of the culprits.
But now I get the error:
EEDI2: maxd must be < 30!EDIT: I searched for "maxd" and it seems to be named "maxdiff" in the script and the the default is 48 for medium. Changing it to something below 30 does not seem to help, the script seems to ignore my user specified setting. When usingMCTemporalDenoise(setings="low",useEEDI2=true)it works finally, even if I illegally set maxdiff to 36 with settings="low". There seems to be something borked in the presets.
I will look deeper into it tomorrow.

Regards
David

Gavino
17th May 2010, 00:20
Taken strictly, this is sign of unkosher scripting ...
Quite so. As I'm sure you know, that sort of thing is best done inside a conditional expression, especially if it involves a less frequently-used external plugin whose use is optional, eg
s = (param == xxx) ? SangNom(...) : NOP()

EDIT: Your clarification came after I posted this.
Your example (as you know) would then be more cleanly written as
filter = do_filter ?
\ use_filterX ? vid.filterX() : vid.filterY()
\ : NOP()

(However if filterX and filterY were both built-in functions, I wouldn't bother doing this unless they were known to have a significant time or memory cost on instantiation.)

LaTo
17th May 2010, 06:41
Quite so. As I'm sure you know, that sort of thing is best done inside a conditional expression, especially if it involves a less frequently-used external plugin whose use is optional, eg
s = (param == xxx) ? SangNom(...) : NOP()
I will add this into the next version, was removed between 1.3.xx -> 1.4.xx (cleaner code) but... it seems to be a problem :D

Gavino
17th May 2010, 11:48
was removed between 1.3.xx -> 1.4.xx (cleaner code) but... it seems to be a problem :D
It's ironic that to clean it up in one respect (readability), it had to become less clean in another (loading unused filters).

Of course, the root of the problem is the limitations of Avisynth's conditional syntax. What you really want to be able to write is something like:

if (AA) {
caa = (useEDDI2 ? .... : ...SangNom(...) ...)
mA = ...
smA = ...
}
else {
...
smA = ...
}
[At this point, I will make my usual plug for GScript. :) ]

Incidentally, on the subject of code cleanup, is there a good reason for using code like
Assert((radius>=1&&radius<=6) ? true : false, ...)

instead of just
Assert(radius>=1&&radius<=6, ...)

Perhaps to get round some perceived bug in Assert?

Joachim Buambeki
17th May 2010, 13:20
Hi LaTo,

can you confirm (or deny) the problem I have with "maxdiff"?

Your script is awesome by the way!

Best Regards
David

LaTo
17th May 2010, 16:05
v1.4.16 :
added switch to avoid loading of unused filters
fixed a bug in anti-aliasing part

:)

LaTo
17th May 2010, 16:10
Incidentally, on the subject of code cleanup, is there a good reason for using code like
Assert((radius>=1&&radius<=6) ? true : false, ...)

instead of just
Assert(radius>=1&&radius<=6, ...)

Perhaps to get round some perceived bug in Assert?
IIRC I had some problems with Assert in the past, so maybe... but it's a bit old for me, I don't remember :confused:

can you confirm (or deny) the problem I have with "maxdiff"?
EEDI2 maxd is maxd in MCTD
Sangnom AA is maxd in MCTD
maxdiff is for another stuff

Great Dragon
17th May 2010, 19:56
For some reason MCTD doesn't process last and first frames in a sequence for me.

Here is an example:
2 last frames in a sequence:
http://a.imagehost.org/t/0531/6381.jpg (http://a.imagehost.org/view/0531/6381) http://a.imagehost.org/t/0406/6382.jpg (http://a.imagehost.org/view/0406/6382)
2 first frames in a next sequence:
http://a.imagehost.org/t/0793/6383.jpg (http://a.imagehost.org/view/0793/6383) http://j.imagehost.org/t/0598/6384.jpg (http://j.imagehost.org/view/0598/6384)

nibus
24th May 2010, 07:41
I'm having trouble when using MCTD on 1080p content. It works fine on everything else but errors out when using 1080p blu ray content:


LoadPlugin("C:\Apps\Multimedia\Video\MeGUI\tools\dgavcindex\DGAVCDecode.dll")
AVCSource("F:\Encode\BluRay\X2\BDMV\STREAM\X2.dga")

crop( 0, 140, 0, -140)

MCTemporalDenoise(settings="medium", edgeclean=true, deblock=true, enhance=true, chroma=true)



This is the error presented in MeGUI:

Error starting job
Exception message
Stacktrace: at MeGUI.core.gui.JobWorker.startEncoding(TaggedJob job)
Inner Exception: null

LaTo
24th May 2010, 07:51
I'm having trouble when using MCTD on 1080p content. It works fine on everything else but errors out when using 1080p blu ray content:


LoadPlugin("C:\Apps\Multimedia\Video\MeGUI\tools\dgavcindex\DGAVCDecode.dll")
AVCSource("F:\Encode\BluRay\X2\BDMV\STREAM\X2.dga")

crop( 0, 140, 0, -140)

MCTemporalDenoise(settings="medium", edgeclean=true, deblock=true, enhance=true, chroma=true)



This is the error presented in MeGUI:

Error starting job
Exception message
Stacktrace: at MeGUI.core.gui.JobWorker.startEncoding(TaggedJob job)
Inner Exception: null

The script works outside of MeGUI?

nibus
24th May 2010, 10:45
The script works outside of MeGUI?

Never encoded outside of MeGUI... I like to be able to preview my filters first so I've steered away from the command line (with video anyway).

Boulder
24th May 2010, 11:08
Try opening the script for example in VirtualDub and see what happens.

Assassinator
25th May 2010, 11:20
AA still seems to be broken.


Used that test script I used last time here (http://forum.doom9.org/showthread.php?p=1394067#post1394067), pretty much exactly the same result.


Want me to upload a short sample + test script?

LaTo
25th May 2010, 11:30
Want me to upload a short sample + test script?

Yes it would be great!

Assassinator
25th May 2010, 12:18
Yes it would be great!

http://zingaburga.com/assassinator/Storage/MCTD_AA_Test.7z

LaTo
25th May 2010, 13:58
v1.4.18 :
fixed anti-aliasing PP (was broken since v1.4.07)
updated MVTools-MaskTools-AddgrainC version

:)

kypec
25th May 2010, 14:56
Would be nice if you could include direct download links to required plugins in your first post.
It took me almost a day to locate appropriate version of this and that tool all over the net. :thanks:

LaTo
25th May 2010, 15:57
Would be nice if you could include direct download links to required plugins in your first post.
It took me almost a day to locate appropriate version of this and that tool all over the net. :thanks:
I think it's a bad idea because it's not a mandatory to have exactly the same version as the documentation, it's just the version that I tested before releasing...

So newer versions should be better unless they introduce major changes in the syntax: if so, say here and I will update the script.

kypec
26th May 2010, 09:23
What I meant to say is: would be nice if there were direct links to sources, developer's pages, whatever else where the plugin's most recent/tested version is to be found. That's all. Searching for them via Doom9 forum or Google is quite tedious and time consuming. Why not to make life a bit easier for those who want to try your scripts? Thanks for your effort.

sinz718
27th May 2010, 19:54
Thanks for this and all but seriously if scripts require other plugs/scripts why not supply them in a rar as well, or the whole thing in a rar?

**

Nevermind I guess this new plugins thread will help me, hopefully.

Die*wrek*show
28th May 2010, 08:28
After spending an entire afternoon searching for, and installing what seemed like every avisynth plugin known to man(I installed more than what I needed just to be sure), my hard work finally paid off.

I get the following error message-

"CAVIStream Synth: Unknown system exception - 0xc000001e at 0xcf23350"

I cannot get this working. So I am back to using plain old dfttest. Does anybody know what causes that error? I'm using

MCTemporalDenoise(Settings="very low",GPU=false)

senseiam
4th June 2010, 19:52
Don't know if anyone else has seen this or not but I am getting "This CLIP is NOT MOD4" errors with mod4 resolutions. When I crop to mod16 script works, no problem.

I tried 1920x1080 (mod4) and I get "THIS CLIP IS NOT MOD4" error

I add Crop(0,4,-0,-4) for 1920x1072 (mod16) works like a charm.

Edit: Using latest version of script

LaTo
5th June 2010, 07:48
After spending an entire afternoon searching for, and installing what seemed like every avisynth plugin known to man(I installed more than what I needed just to be sure), my hard work finally paid off.

I get the following error message-

"CAVIStream Synth: Unknown system exception - 0xc000001e at 0xcf23350"

I cannot get this working. So I am back to using plain old dfttest. Does anybody know what causes that error? I'm using

MCTemporalDenoise(Settings="very low",GPU=false)

I think it's a broken plugin, check one by one.




Don't know if anyone else has seen this or not but I am getting "This CLIP is NOT MOD4" errors with mod4 resolutions. When I crop to mod16 script works, no problem.

I tried 1920x1080 (mod4) and I get "THIS CLIP IS NOT MOD4" error

I add Crop(0,4,-0,-4) for 1920x1072 (mod16) works like a charm.

Edit: Using latest version of script

No problem with 1920x1080 in my side, provide the exact script used and a little sample clip please.

Boulder
6th June 2010, 15:45
Is is possible to make the MT function work with MCTemporalDenoise? I only get a garbled error message with MT("MCTemporalDenoise()"), also using triple quotes doesn't help.

elguaxo
6th June 2010, 17:00
Is is possible to make the MT function work with MCTemporalDenoise?

It has always worked for me. Don't know if it makes a difference, but I'm still using AviSynth 2.5.7 + MT 0.7 (http://forum.doom9.org/showthread.php?t=94996).

Boulder
6th June 2010, 17:05
Strange, it seems to work on my computer but not on my dad's computer, from where I got the error message. The plugins and Avisynth versions should be pretty much equal, SEt's Avisynth 2.5.8MT installed. I've got to try emptying the plugins folder on his computer the next I visit my folks.

LaTo
6th June 2010, 17:09
Sorry I never use MT version...

darkelf5
11th June 2010, 15:58
I've tried it with AviSynth x64 build.
Everything works, except enabling GPU. I've tested it on a simple script
AVIsource("blablabla")
MCTemporalDenoise("GPU=true")
And this is what i get:
http://img256.imageshack.us/img256/5532/21616589.jpg (http://img256.imageshack.us/i/21616589.jpg/)

LaTo
11th June 2010, 15:59
I've tried it with AviSynth x64 build.
Everything works, except enabling GPU. I've tested it on a simple script
AVIsource("blablabla")
MCTemporalDenoise("GPU=true")
And this is what i get:
http://img256.imageshack.us/img256/5532/21616589.jpg (http://img256.imageshack.us/i/21616589.jpg/)

It should be a problem with FFT3Dgpu.

lych_necross
22nd June 2010, 07:15
Is there a chance that this script will become a dll like with SmoothAdjust? If so, what about LSFmod?

LaTo
22nd June 2010, 11:46
Is there a chance that this script will become a dll like with SmoothAdjust?
No, too complicated for me.

If so, what about LSFmod?
Maybe later, but at this time I don't see any big improvement to achieve this and I'm lazy ;)

asarian
25th June 2010, 20:31
Earlier I had some trouble (http://forum.doom9.org/showthread.php?p=1405474) with TemporalDegrain, as part of a scene would bleed into the next on certain scene changes. So I looking for a temporal denoiser that will denoise without these faults, and I'm hoping MCTemporalDenoise is it. :) So, is this program 'safe' for general use? Kinda hate spending enother hundred or so hours on encoding, only to find out the output is messed up again.

I got the impression, from the other thread, that temporal degraining is inherently hard to accomplish; so maybe a truly 'safe' filter in that regard does not exist. But I'm hoping people's experiences with MCTemporalDenoise are good.

Thanks.

LaTo
25th June 2010, 20:41
Earlier I had some trouble (http://forum.doom9.org/showthread.php?p=1405474) with TemporalDegrain, as part of a scene would bleed into the next on certain scene changes. So I looking for a temporal denoiser that will denoise without these faults, and I'm hoping MCTemporalDenoise is it. :) So, is this program 'safe' for general use? Kinda hate spending enother hundred or so hours on encoding, only to find out the output is messed up again.

I got the impression, from the other thread, that temporal degraining is inherently hard to accomplish; so maybe a truly 'safe' filter in that regard does not exist. But I'm hoping people's experiences with MCTemporalDenoise are good.

Thanks.


Yes, it's safe for general use... Especially with limit=-1 & limit2=-1 ;)

asarian
25th June 2010, 20:47
Yes, it's safe for general use... Especially with limit=-1 & limit2=-1 ;)
Thank you very much! :) I'll go install it rightaway!

LaTo
25th June 2010, 20:53
Thank you very much! :) I'll go install it rightaway!

Just one thing: adjust sigma for your source, it should be the lowest while keeping it's efficiency.

Didée
25th June 2010, 22:02
Just one thing: adjust sigma for your source, it should be the lowest while keeping it's efficiency.
That was exactly his problem with TemporalDegrain: usage of default sigma's, which was too strong for his source...

The underlying problem with using FFT3DFilter as prefilter is that FFT3D is generally not safe on scenechanges. Is there any special SC-protection in MCTD to compensate for that?

LaTo
26th June 2010, 09:34
The underlying problem with using FFT3DFilter as prefilter is that FFT3D is generally not safe on scenechanges. Is there any special SC-protection in MCTD to compensate for that?
No SC-protection in MCTD... But I have never experienced SC problem with MCTD, it may be due to reasonable sigma values in preset.

If FFT3D really miss a scene change, try to use limit=x / limit2=x (instead of -1).
"x" should be a positive value but the lowest possible (it's a simple limiting threshold).
If the clip isn't so grainy, bt=1 should fix the problem also.

Maybe I will implement a SC-protection in MCTD with SCSelect if the problem persist, but I doubt.
Truly I use FFT3D all the time without problem, so I want to see a sample/script (with appropriate sigma) where FFT3D miss a scene change... Someone please? I am curious :)

Didée
26th June 2010, 09:52
where FFT3D miss a scene change...
It doesn't miss "a" scenechange. It does miss *every* scenechange. To my knowledge, temporal processing of FFT3DFilter simply doesn't check or care for that.

Just set bt=5,sigma=16, and watch what happens.

Of course it's mostly not a problem with lower sigmas. But that doesn't mean the issue isn't there. It's just that the problem becomes much harder to notice (and that's why people aren't complaining) ... but *present* it is all the time.

LaTo
26th June 2010, 16:41
It doesn't miss "a" scenechange. It does miss *every* scenechange. To my knowledge, temporal processing of FFT3DFilter simply doesn't check or care for that.

Just set bt=5,sigma=16, and watch what happens.

Of course it's mostly not a problem with lower sigmas. But that doesn't mean the issue isn't there. It's just that the problem becomes much harder to notice (and that's why people aren't complaining) ... but *present* it is all the time.

Argh you're right... Hardly noticeable but it's here with high sigma in FFT3Dfilter :(

senseiam
27th June 2010, 09:11
Don't know if anyone else has seen this or not but I am getting "This CLIP is NOT MOD4" errors with mod4 resolutions. When I crop to mod16 script works, no problem.

I tried 1920x1080 (mod4) and I get "THIS CLIP IS NOT MOD4" error

I add Crop(0,4,-0,-4) for 1920x1072 (mod16) works like a charm.

Edit: Using latest version of script


No problem with 1920x1080 in my side, provide the exact script used and a little sample clip please.


Don't have a specific sample clip handy right now but I get this on multiple different sources so I have to crop after or crop to mod16.

Script example:

Import("\AviSynth 2.5\plugins\MCTemporalDenoise.avs")
Import("\AviSynth 2.5\plugins\GradFun2DBmod.v1.5.avs")
SetMemoryMax(2048)

AVCSource("something.dga")

Crop(0,20,-0,-20)

MT(""" MCTemporalDenoise(settings="very low",sigma=6,chroma=true,stabilize=true,GPU=false,ncpu=8,enhance=true,sharp=false) """, threads=8, overlap=16)

Even though it's 1920x1040, mod16, it doesn't want to work, reports this isn't mod4.

LaTo
27th June 2010, 09:14
Don't have a specific sample clip handy right now but I get this on multiple different sources so I have to crop after or crop to mod16.

Script example:

Import("\AviSynth 2.5\plugins\MCTemporalDenoise.avs")
Import("\AviSynth 2.5\plugins\GradFun2DBmod.v1.5.avs")
SetMemoryMax(2048)

AVCSource("something.dga")

Crop(0,20,-0,-20)

MT(""" MCTemporalDenoise(settings="very low",sigma=6,chroma=true,stabilize=true,GPU=false,ncpu=8,enhance=true,sharp=false) """, threads=8, overlap=16)

Even though it's 1920x1040, mod16, it doesn't want to work, reports this isn't mod4.

MT is the problem, use SetMTMode... (or adjust threads in MT: "height/threads" must be mod4)

Gavino
27th June 2010, 10:02
MT is the problem, use SetMTMode... (or adjust threads in MT: "height/threads" must be mod4)
Or use splitvertical=true, since width/threads is already mod4.

Boulder
27th June 2010, 13:35
It doesn't miss "a" scenechange. It does miss *every* scenechange. To my knowledge, temporal processing of FFT3DFilter simply doesn't check or care for that.I wonder if anyone with some programming skills could add scenechange detection if Fizick doesn't want to do that. It should be quite simple since there are many filters to borrow code from (of course it depends on the case, but still..)

senseiam
27th June 2010, 20:07
Or use splitvertical=true, since width/threads is already mod4.

ok thanks! :)

asarian
28th June 2010, 00:37
I wonder if anyone with some programming skills could add scenechange detection if Fizick doesn't want to do that. It should be quite simple since there are many filters to borrow code from (of course it depends on the case, but still..)
I second that motion. :) I'm not versed enough in the intricacies of motion estimation to even begin to think about doing it myself; but it would be great if someone would actually fix it.

asarian
29th June 2010, 04:40
LaTo, I may not be doing it entirely right yet. :) I'm using this avs script on a 1-minute clip:

LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\FFMS2.dll")
Loadplugin("C:\Program Files\AviSynth 2.5\plugins\FFT3DFilter.dll")
Loadplugin("C:\Program Files\AviSynth 2.5\plugins\mt_masktools-25.dll")
Loadplugin("C:\Program Files\AviSynth 2.5\plugins\mvtools2.dll")
Loadplugin("C:\Program Files\AviSynth 2.5\plugins\RemoveGrainSSE3.dll")
Loadplugin("C:\Program Files\AviSynth 2.5\plugins\TTempSmooth.dll")
Loadplugin("C:\Program Files\AviSynth 2.5\plugins\RepairSSE3.dll")
Loadplugin("C:\Program Files\AviSynth 2.5\plugins\deblock.dll")
Loadplugin("C:\Program Files\AviSynth 2.5\plugins\DctFilter.dll")
Loadplugin("C:\Program Files\AviSynth 2.5\plugins\EEDI2.dll")
Loadplugin("C:\Program Files\AviSynth 2.5\plugins\SangNom.dll")
Loadplugin("C:\Program Files\AviSynth 2.5\plugins\gradfun2db.dll")
Loadplugin("C:\Program Files\AviSynth 2.5\plugins\AddGrainC.dll")

video=FFVideoSource("M:\jobs\2010test.mkv").ConvertToYV12()
video=MCTemporalDenoise(video, settings="very high")
video=Crop(video, 0, 142, 0, -142)

return video

Nothing happens for a long while, though. First I get a Windoze error, saying it can't use "mt_masktools-25-x64.dll" (of course it can't: I'm on 32bit; and I didn't ask for it to be run, either). Then x264 keeps hovering around 25% CPU, steadily increasing in memory size (to around 1.4GB). And finally it tells me that 1 minute clip, at 0.00fps, (sic!) will take over 300 hours! Why, that seems a mite extreme. :)

x264 remains at ca. 25% CPU. So, I guess I'm doing something wrong. Any hints?

tormento
29th June 2010, 06:58
I wonder if anyone with some programming skills could add scenechange detection if Fizick doesn't want to do that.
And a x64 version too =P

Didée
29th June 2010, 08:48
And a x64 version too =P
There already is one (http://code.google.com/p/avisynth64/wiki/PluginLinks). (Without SC detection, of course.)