View Full Version : Port of NNEDI under new v2.6 AVS API
Pages :
1
2
3
4
5
[
6]
7
8
9
10
11
12
13
jpsdr
23rd May 2016, 08:56
No news, good news ? MT version is working perfectly fine ?
pinterf
23rd May 2016, 10:42
Immediate crash in avs+
LoadPlugin(".\nnedi3.dll")
SetFilterMTMode("DEFAULT_MT_MODE", 3)
Avisource("dv_Hi8.avi",audio=false).trim(0, 499)
ConvertToYV12()
nnedi3_rpow2(2, Threads=1)
Prefetch(2)
without MT it works fine.
December 23, 2015 version did not crash (but is showing garbage as we know).
Reel.Deel
23rd May 2016, 13:15
I had a similar experience to pinterf. Instantly crashed VDub and AVSMeter. VDub error message: "The instruction at 0x5d76a138 referenced memory at 0x484c29e0. The memory could not be written."
LoadPlugin("nnedi3.dll")
SetFilterMTMode("nnedi3", 1)
SetFilterMTMode("nnedi3_rpow2", 1)
ColorBars(pixel_type="YV12")
nnedi3_rpow2(2)
Prefetch(4)
jpsdr
23rd May 2016, 13:28
Ok... :(
... First thought is the fact that some threads can't change mutex status... Will try to see...
Edit :
Hum... Forcing an MT statuts on not MT avs to force the use of the code using mutex and event works, so, my first thought seems right, the LPSECURITY_ATTRIBUTES probably doesn't allow some threads to acces mutex and/or event...
MysteryX
23rd May 2016, 15:57
I will point out, however, that calling NNEDI3 through edi_rpow2 script does work in MT... somehow.
Reel.Deel
23rd May 2016, 16:14
I will point out, however, that calling NNEDI3 through edi_rpow2 script does work in MT... somehow.
That's because edi_rpow2 is a script function. If nnedi3_rpow2 was an actual script it would also work. Currently nnedi3_rpow2 is a script written in C++. This creates problems in AviSynth+ MT, read here (http://forum.doom9.org/showthread.php?p=1768086#post1768086) and subsequent posts.
jpsdr
30th May 2016, 20:32
After several unsuccesfull tries, i've gone to very basic.
nnedi3 and nnedi3_rpow2 report themselves as MT_MULTI_INSTANCE if an MT version of avisynth is detected, and in case it wouldn't be enough, i've add a mutex preventing several getframe running from the same instance filter for safety.
New version on first page.
MysteryX
12th July 2016, 05:48
This build is not compatible with the latest Avisynth+. A new build is required.
jpsdr
12th July 2016, 08:49
I know, but i want to build "once for all", so i still have to update VS2015 to Updt 3, and with each new update of VS, comes a new version of Intel Compiler (well, most of the time). So, i'll wait a little to see if a new IC pops up or not before doing anything. Dont want to waste time installing/uninstalling several times, and don't want to build to see a new IC poping just a few days after posting it. If within a few weeks nothing pops, i'll update my VS2015 to Updt3 and make a new build. if something pops before, i'll do it at this time.
MysteryX
12th July 2016, 13:13
You could just change the headers file and recompile with what you have.
There might also be another version of AVS+ coming, with possibly new headers, and it might become possible to register the MT mode without using env2. There are several things to wait for. Just doing a quick recompile would allow people to keep using NNEDI3 in the mean-time and not have to rush for doing a proper compile.
jpsdr
12th July 2016, 13:27
I've tried to build a new version at work (under VS2010), and now i have something i didn't have before :
1>c:\documents and settings\jean-philippe.scotto\mes documents\perso\vs2010\nnedi3\nnedi3\avisynth.h(115): error C2059: erreur de syntaxe*: ';'
1>c:\documents and settings\jean-philippe.scotto\mes documents\perso\vs2010\nnedi3\nnedi3\avisynth.h(115): error C2238: jetons inattendus avant ';'
1>c:\documents and settings\jean-philippe.scotto\mes documents\perso\vs2010\nnedi3\nnedi3\avisynth.h(570): error C2059: erreur de syntaxe*: ';'
1>c:\documents and settings\jean-philippe.scotto\mes documents\perso\vs2010\nnedi3\nnedi3\avisynth.h(570): error C2238: jetons inattendus avant ';'
1>c:\documents and settings\jean-philippe.scotto\mes documents\perso\vs2010\nnedi3\nnedi3\avisynth.h(624): error C2059: erreur de syntaxe*: ';'
1>c:\documents and settings\jean-philippe.scotto\mes documents\perso\vs2010\nnedi3\nnedi3\avisynth.h(624): error C2238: jetons inattendus avant ';'
1>c:\documents and settings\jean-philippe.scotto\mes documents\perso\vs2010\nnedi3\nnedi3\avisynth.h(115): error C2059: erreur de syntaxe*: ';'
1>c:\documents and settings\jean-philippe.scotto\mes documents\perso\vs2010\nnedi3\nnedi3\avisynth.h(115): error C2238: jetons inattendus avant ';'
1>c:\documents and settings\jean-philippe.scotto\mes documents\perso\vs2010\nnedi3\nnedi3\avisynth.h(570): error C2059: erreur de syntaxe*: ';'
1>c:\documents and settings\jean-philippe.scotto\mes documents\perso\vs2010\nnedi3\nnedi3\avisynth.h(570): error C2238: jetons inattendus avant ';'
1>c:\documents and settings\jean-philippe.scotto\mes documents\perso\vs2010\nnedi3\nnedi3\avisynth.h(624): error C2059: erreur de syntaxe*: ';'
1>c:\documents and settings\jean-philippe.scotto\mes documents\perso\vs2010\nnedi3\nnedi3\avisynth.h(624): error C2238: jetons inattendus avant ';'
"erreur de syntaxe" means "syntax error"....:(
Out of question for me to use something which can't be compiled under at least VS2010. While the avisynth header is not fixed, i'll use my previous one.
EDIT : removing delete and replacing by {return(*this);} fixed the issue.
jpsdr
14th July 2016, 11:14
I've updated from r1858 to r2043, but still haven't re-compiled my filters (including nnedi), and everything works fine. Avsmeter report that i'm indeed with r2043. I'm under Win7x64, and opening the avs file with VDubx64 works fine. I expected a crash according what i've read, but not... Strange.
Reel.Deel
14th July 2016, 14:32
I've updated from r1858 to r2043, but still haven't re-compiled my filters (including nnedi), and everything works fine. Avsmeter report that i'm indeed with r2043. I'm under Win7x64, and opening the avs file with VDubx64 works fine. I expected a crash according what i've read, but not... Strange.
I reported the same thing (http://forum.doom9.org/showthread.php?p=1772768#post1772768), for some strange reason X64 plugins using IScriptEnv2 work. I asked ultim about it:
<Reel_Deal> ultim, why is that only 32-bit is affected?
<ultim> the manifestation of the problem depends partially on the how internal memory layout of IScriptEnv2 is changed by the compiler after GetVarDef was added to IScriptEnv. it might be that due to some kind of padding the offsets of the vtable in IScriptEnv2 do not change at all for x64 builds.
<ultim> it is also possible though that the interface is equally broken in x64, but you'd only see it later due to internal state corruption
<ultim> to know which of these is the case, someone with deep knowledge of MSVC++ compiler internals would be necessary
<ultim> this means i wouldn't rely on x64 being correct until testing for days and tens of thousands of frames
jpsdr
15th July 2016, 12:49
New version, see first post.
Magik Mark
18th July 2016, 08:06
May I ask a good parameter for chroma upscaling? Similar to madvr
jpsdr
23rd July 2016, 12:12
New version, see first post.
jpsdr
12th August 2016, 20:01
New version, minor update.
jpsdr
30th August 2016, 20:39
New version, see first page.
Update to use my threadpool. I've made a few bench, speed seems similar, but the number of threads is reduced. Of course, the more cores you have, the more it's noticeable.
Reel.Deel
30th August 2016, 20:53
New version, see first page.
Update to use my threadpool. I've made a few bench, speed seems similar, but the number of threads is reduced. Of course, the more cores you have, the more it's noticeable.
Just out of curiosity, why do you delete the previous releases? Sometimes it comes in handy to have them.
bilditup1
31st August 2016, 04:49
Any reason why the XP builds would perform faster than the W7 builds on a W10 machine using avs+ mt r2172? I tried this a few times by accident. The first two times I got an increase in speed of 1.5fps, the last time of .6fps. In between, there was some instability - it would either quit after one frame or come to a complete halt (stops processing frames, but doesn't quit or become unresponsive). The instability I expected, but the increase in speed of the XP_Core2_SSE4.2 build relative to the W7_Core2_SSE4.2 build was not.
ryrynz
31st August 2016, 06:52
Any reason why the XP builds would perform faster than the W7 builds on a W10 machine using avs+ mt r2172?
If it's that unstable what's the point in asking? It's obviously not working right.
+ Add a thread parameter for the resampler if use of the MT resamplers.
Can you provide some additional information about this? Examples?
Groucho2004
31st August 2016, 08:34
In between, there was some instability - it would either quit after one frame or come to a complete halt (stops processing frames, but doesn't quit or become unresponsive).
If you're referring to this (http://forum.doom9.org/showthread.php?p=1779369#post1779369) script, you have to consider that you're running a complex script (QTGMC) and combining two different multi-threading systems. This is usually not a good idea, you should stick with just using "Prefetch()" and disable the internal multi-threading of plugins (EdiThreads = 0, DftThreads = 0).
jpsdr
31st August 2016, 08:43
Can you provide some additional information about this? Examples?
It's in the readme of the release.
And, consider my release for people like me, who are not using the internal multi-threading of avs+ (or Set version). If you want to use the internal multi-threading of avisynth, stays with standard resamplers, and set nnedi threads to 1.
I'll even check if i can make another step/modification to nnedi, to not use at all the threadpool if the number of threads is 1. For now, it's still like the original version, always using the threadpool, whatever the number of threads.
I advance one step at the time.
bilditup1
31st August 2016, 11:46
If it's that unstable what's the point in asking? It's obviously not working right.
Eh, so sue me for being curious.
If you're referring to this (http://forum.doom9.org/showthread.php?p=1779369#post1779369) script, you have to consider that you're running a complex script (QTGMC) and combining two different multi-threading systems. This is usually not a good idea, you should stick with just using "Prefetch()" and disable the internal multi-threading of plugins (EdiThreads = 0, DftThreads = 0).
Thanks for the tip.
ED: Looking at the wiki, it appears both that 0 is the default for each of those settings, and that 0 denotes 'set amount of threads equal to logical cores'. Has this changed?
jpsdr
31st August 2016, 12:32
A little, it's now equal to the number of physical cores, because after some testbench, i realised that it was what produced the best result.
BTW, when i said that my release "are not" for those who use internal MT, it doesn't mean it's not working. It's intended to work, it's designed to work with, it must work with, but it's just that it may not be the optimal result, and will probably not be. All my release are only MT_MULTI_INSTANCE, not MT_NICE_FILTER, because not intended to and not compatible with.
A new release with minor fix and not use of poolthread when threads=1 in a few hours.
jpsdr
31st August 2016, 18:49
Finaly, new release is delayed, i've think of something i want to add. Expect more this WE.
ryrynz
1st September 2016, 04:00
I'm getting a no function named error with nnedi3_rpow2, when running through ffdshow with both W7 releases. No issues with .24.
jpsdr
1st September 2016, 07:53
Euh... Sorry, absolutely no idea, as i'm not using ffdshow at all (and have no idea how it works)... I'm only using VDub (and avsmeter to check sometimes).
If something goes wrong, there should be a message throw by env->ThrowError. Do you have any ? The nnedi3_rpow2 is still properly added to avisynth, because otherwise it wouldn't work at all.
The only other option i can see should be if some dll (but i don't require any specific) would be missing. But i think you're up to date to all the redustribuable.
Groucho2004
1st September 2016, 07:59
I'm getting a no function named error with nnedi3_rpow2
The most common causes for this error are:
Wrong bittage (32 bit process loading 64 bit DLL and vice versa)
MS runtime missing
ryrynz
1st September 2016, 09:52
The most common causes for this error are:
Wrong bittage (32 bit process loading 64 bit DLL and vice versa)
MS runtime missing
I updated the redistributables with the AIO only a month ago.. guess I'll run the latest release..
..
And yeah that fixed it.. surprisingly the AIO gives you no info about it not updating any redistributable to the latest version, it just says it's already installed. Only by uninstalling those packages not stamped with latest date and then running the AIO again do I see that there were updates that were not applied.
If these are so critical to apps working right and are updated reasonably often it's a wonder that Windows doesn't do a better job of keeping them up to date. Anyway thanks, that made me go through and make sure everything's up to date.
But i think you're up to date to all the redustribuable.
Yeah I thought I was too. =/
Groucho2004
1st September 2016, 10:52
I updated the redistributables with the AIO only a month ago.. guess I'll run the latest release..
..
And yeah that fixed it.. surprisingly the AIO gives you no info about it not updating any redistributable to the latest version, it just says it's already installed. Only by uninstalling those packaging not stamped with latest date and then running the AIO again do I see that there were updates that were not applied.
If these are so critical to apps working right and are updated reasonably often it's a wonder that Windows doesn't do a better job of keeping them up to date.
The frequent runtime updates can be a pain in the butt. Usually the developer distributes the correct runtimes with the software (as for example ultim does with his avisynth builds). At the very least the developer should write a note which runtimes including the exact version number are required.
ryrynz
1st September 2016, 11:58
At the very least the developer should write a note which runtimes including the exact version number are required.
Are runtime version errors even something Avisynth can display? Surprised there isn't some logging of this error TBH.
BTW jpsdr, do you know how much of an impact the AVX512 instructions make with this? Anyone with a Xeon? General mainstream users gotta wait until Cannonlake or newer before we can try it,
I'm curious what it brings to the table.
jpsdr
1st September 2016, 15:31
BTW jpsdr, do you know how much of an impact the AVX512 instructions make with this?
Not realy, i have a lot of cores ;), but i don't have AVX512 neither. I just make the build in case someone would be interested with.
In one of the ReadMe, i say with what version exactly it's build.
jackoneill
1st September 2016, 20:27
None at all, considering that the AVX512 instructions, if any are actually used, end up in functions where barely any CPU time is spent. The functions that matter are all written in asm, and the compiler never touches them.
This applies to the SSE4.2 and AVX2 binaries as well.
jpsdr
2nd September 2016, 17:23
New version, see first post.
I've added several parameter to allow to tune the created threadpool. I've made several testbench, and set the default settings correspond to the best result i have on my PC. But, it doesn't mean it will be also what produce the best result on others PC, so, the parameters added will allow to eventualy each one tune according his hardware configuration.
Check the ReadMe file for precise information.
Sm3n
25th September 2016, 10:13
Hi,
I'm having issues with this plugin. I'm using AVS+r1858-pfmod both x86 and x64 can I load it into this mod? I assume I do.
The error are the next: avspmod is freezing or "System exception - Illegal Instruction".
I have to go back with the old nnedi3.
jpsdr
25th September 2016, 10:50
I think you're using a "wrong" Intel version build, using instructions not supported by your CPU. In that case, first begin by using just the standard version, not the Intel.
Sm3n
25th September 2016, 11:27
I think you're using a "wrong" Intel version build, using instructions not supported by your CPU. In that case, first begin by using just the standard version, not the Intel.
That was my first guess ^^ and based on what x264 says "cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX" I tried all intel.
I'll check the standard.
thx for your support
Edit: OK I found the good one: "Release_Intel_W7_Core2_SSE4.2"
dandyclubs
28th September 2016, 09:27
D:\Worker\AVSMeter>AVSMeter.exe -avsinfo
AVSMeter 2.4.1 (x86) - Copyright (c) 2012-2016, Groucho2004
VersionString: AviSynth+ 0.1 (r2172, MT, i386)
VersionNumber: 2.60
File version: 0.1.0.0
Interface Version: 6
Multi-threading support: Yes
Linker/compiler version: 14.0
Avisynth.dll location: C:\Windows\SysWOW64\AviSynth.dll
Avisynth.dll time stamp: 2016-08-19, 15:51:34
PluginDir+ (HKLM, x86): C:\Program Files (x86)\AviSynth+\plugins+
PluginDir2_5 (HKLM, x86): C:\Program Files (x86)\AviSynth+\plugins
[CPP 2.5 plugins]
C:\Program Files (x86)\AviSynth+\plugins+\EEDI2.dll [0.9.2.0]
[CPP 2.6 plugins]
C:\Program Files (x86)\AviSynth+\plugins+\ConvertStacked.dll [n/a]
C:\Program Files (x86)\AviSynth+\plugins+\DirectShowSource.dll [n/a]
C:\Program Files (x86)\AviSynth+\plugins+\ImageSeq.dll [n/a]
C:\Program Files (x86)\AviSynth+\plugins+\masktools2.dll [2.1.0.0]
C:\Program Files (x86)\AviSynth+\plugins+\mvtools2.dll [2.7.0.22]
C:\Program Files (x86)\AviSynth+\plugins+\nnedi3.dll [0.9.4.27]
C:\Program Files (x86)\AviSynth+\plugins+\RgTools.dll [n/a]
C:\Program Files (x86)\AviSynth+\plugins+\Shibatch.dll [n/a]
C:\Program Files (x86)\AviSynth+\plugins+\TimeStretch.dll [n/a]
C:\Program Files (x86)\AviSynth+\plugins+\VDubFilter.dll [n/a]
[Plugin errors/warnings]
----------------------------------------------------------------------------------------------------------------------
Cannot load file 'C:/Program Files (x86)/AviSynth+/plugins+/nnedi3.dll'. Platform returned code 126:
지정된 모듈을 찾을 수 없습니다.
Dependencies that could not be loaded:
libiomp5md.dll
----------------------------------------------------------------------------------------------------------------------
so i get libiomp5md.dll file form Linx
copy to C:\Windows\SysWOW64
i have Intel 5820k
so copy nnedi3.dll from Release_Intel_W7_Core2_AVX2
but not work.
i add EdiThreads = 0, DftThreads = 0
QTGMC( Preset="Faster" , EdiThreads = 0, DftThreads=EdiThreads )
run AVSMeter test.avs
avx2 build is not work.
i change nnedi3.dll from Release_Intel_W7_Core2_SSE4.2
sse4.2 build is work...
i want NNEDI3 0.9.4.24 or 23
old NEEDI upload plz
ryrynz
28th September 2016, 10:11
I can't get .27 or .26 to work, I just get a black screen unless I remove prefetch or set it to 1. Tested .27 W7 and W7 SSE & AVX512 releases.
ffdshow_source()
nnedi3_rpow2(rfactor=2, nsize=4, nns=1,cshift="Spline36Resize")
Prefetch(4)
.25 works as expected.
old NEEDI upload plz
.24
https://uploadfiles.io/b2057
.25
https://uploadfiles.io/0b059
dandyclubs
28th September 2016, 10:45
.24 & .25
https://ufile.io/bf71111
this bf71111-writing---andrea-a-lunsford---the-st.-martins-handbook-with-2009-mla.PDF file
ryrynz
28th September 2016, 11:58
this bf71111-writing---andrea-a-lunsford---the-st.-martins-handbook-with-2009-mla.PDF file
Dunno what happened there. Fixed link.
dandyclubs
28th September 2016, 12:31
.25
https://uploadfiles.io/0b059
25 avx2 build fine work.
thanks!!
jpsdr
28th September 2016, 18:54
... It seems there is something between my threadpool and the core multithreading, even if theoricaly it shouldn't, as the version match the introduction of it.
I will not have the possibility to take a look before a long time... And when i think about it, not before next year indeed...
jpsdr
6th October 2016, 19:19
I thought of a little something, so new version, give it a try to see if prefetch is working again or not.
ryrynz
7th October 2016, 14:09
SetFilterMTMode("DEFAULT_MT_MODE", 2)
ffdshow_source()
nnedi3_rpow2(rfactor=2, nsize=4, nns=1,cshift="Spline36Resize")
Prefetch(4)
Gives me a black screen. Removing prefetch makes it work.
jpsdr
7th October 2016, 15:56
So, it wasn't the little something... Ok.
jpsdr
11th October 2016, 18:21
New version, fix a deadlock possible case. I've tried to test Prefetch, but i had an error message saying that only one Prefetch is allowed by script, even if my script has only one Prefetch line, so... Those who have a working MT version, feel free to test this new release.
pinterf
11th October 2016, 19:43
There is a missing dll:
32 bit W7 Core2 SSE4.2:
Cannot load file 'C:/Program Files (x86)/AviSynth/plugins/nnedi3.dll'. Platform returned code 126:
Dependencies that couldn't be loaded:
libiomp5md.dll
The regular Release W7 is O.K.
ryrynz
11th October 2016, 23:42
64 bit AVX2 release is working fine for me.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.