DGDenoise

These CUDA filters are packaged into DGDecodeNV, which is part of DGDecNV.
Post Reply
Selur
Distinguished Member
Distinguished Member
Posts: 112
Joined: Mon Nov 05, 2012 4:49 pm

DGDenoise

Post by Selur » Sat Aug 20, 2016 7:53 am

using:

Code: Select all

SetMemoryMax(768)
SetMTMode(5,8) # change MT mode
LoadCPlugin("G:\Hybrid\AVISYN~1\ffms2.dll")
LoadPlugin("G:\Hybrid\AVISYN~1\DGDENO~1.DLL")
# loading source: F:\TestClips&Co\Test-AC3-5.1.avi
FFVideoSource("F:\TESTCL~1\TEST-A~1.AVI",cachefile="H:\Temp\avi_54a4199c1a3d3b1476ea1d15dc267332_4827_1_0.ffindex",fpsnum=25)
# denoising using DGDenoise
SetMTMode(2) # change MT mode
ConvertToRGB32(interlaced=false)
DGDenoise()
return last
I get:

Code: Select all

DGDenoise: could not start the denoise server!
Any idea what I could look into? Or what info I should/could provide to help to find the problem,..

Cu Selur

User avatar
admin
Site Admin
Posts: 4382
Joined: Thu Sep 09, 2010 3:08 pm

Re: About DGDenoise

Post by admin » Sat Aug 20, 2016 10:39 am

Hi Selur,

Of course I'd love to help my good buddy Selur to get this working. First please redownload DGDenoise.rar and update all the files. Be sure to use the proper 32 or 64 bit files. Suppose you have 32-bit, then put all the 32-bit files into a directory.

Now make sure that there is no stuck DenoiseServer.exe running in the Task Manager.

Then for the first test, move to that directory, open a CMD window, and type 'DenoiseServer'. It should start without error. If it doesn't please tell me what is printed. If it does start OK, then kill it in the Task Manager and try this simple script:

loadplugin("DGDenoise.dll") # all the files must be here with this DLL
BlankClip().ConverttoRGB32
DGDenoise()

Then report.

We'll continue based on your results. Thank you for helping me. For me, it is working as good as KNLMeansCL but much faster.

User avatar
admin
Site Admin
Posts: 4382
Joined: Thu Sep 09, 2010 3:08 pm

Re: About DGDenoise

Post by admin » Sat Aug 20, 2016 10:44 am

A few more things... Please search your system and see if you have an opencl.dll anywhere. Finally, what OS, avisynth version, nVidia card, and nVidia driver?

Selur
Distinguished Member
Distinguished Member
Posts: 112
Joined: Mon Nov 05, 2012 4:49 pm

Re: About DGDenoise

Post by Selur » Sat Aug 20, 2016 11:11 am

Downloaded and extracted the content of the new DGDenoise.rar, overwriting the old files.
Double clicking or alternatively starting DenoiseServer.exe works without a problem. No error messages or similar and the running program is show inside the task manager.

Still opening the script produces the error,no matter whether DenoiseServer was already running or not.

regarding the opencl.dll:
got one in the same folder as DGDecode (came with KNLMeansCL; removing it from the folder didn't change a thing
got one inside the Windows/System32 folder; removing it from the folder didn't change a thing
got one inside the Windows/_SysWOW64 folder; removing it from the folder didn't change a thing
(tried all combinations)

also got opencl.dll inside:

Code: Select all

C:\Windows\WinSxS\wow64_microsoft-windows-r..xwddmdriver-wow64-c_31bf3856ad364e35_10.0.14393.0_none_de9cd86dc2ec8d588
(didn't touch that one)

btw. I'm using the 32bit version of the files together with Avisynth MT on a 64bit Windows 10 pro system.

Cu Selur

User avatar
admin
Site Admin
Posts: 4382
Joined: Thu Sep 09, 2010 3:08 pm

Re: About DGDenoise

Post by admin » Sat Aug 20, 2016 11:19 am

OK, you have everything you need to start the server and run the CUDA code. Never try to start a script with the DenoiseServer already running. I know you tried both ways but just warning you.

So we must have an issue in the Avisynth filter itself. Strange, because all it does is query the path for DGDenoiseServer.exe and then start it with ShellExecute().

Maybe the MT stuff and 32-bit stuff on 64 is a problem. Would it be too hard to run Avs+ 64 2085 (with no MT enabled) and the 64-bit filter just to test? If so, please try it. Meanwhile I will make a version of the filter that pops up the ShellExecute() error that is encountered. Stand by for that.

Thanks for your testing.

Selur
Distinguished Member
Distinguished Member
Posts: 112
Joined: Mon Nov 05, 2012 4:49 pm

Re: About DGDenoise

Post by Selur » Sat Aug 20, 2016 11:23 am

Will look into Avisynth+ and the 64bit version (will take some time).

User avatar
admin
Site Admin
Posts: 4382
Joined: Thu Sep 09, 2010 3:08 pm

Re: About DGDenoise

Post by admin » Sat Aug 20, 2016 11:27 am

OK, I uploaded the modified filters. Maybe try that first to get the error data.

Selur
Distinguished Member
Distinguished Member
Posts: 112
Joined: Mon Nov 05, 2012 4:49 pm

Re: About DGDenoise

Post by Selur » Sat Aug 20, 2016 12:09 pm

Updated the files, now I get the message:

Code: Select all

DGDenoise: could not start the denoise server G:\Hybrid\dynamic\DenoiseServer.exe, error 2!
Also as a side note:
I did a quick test with the 64bit version and Vapoursynth R33 RC1 using:

Code: Select all

# Imports
import vapoursynth as vs
core = vs.get_core()
# Loading Plugins
core.avs.LoadPlugin(path="G:/Hybrid/Vapoursynth/vapoursynth64/plugins/DenoiseFilter/DGDenoise/DGDenoise.dll")
core.std.LoadPlugin(path="G:/Hybrid/Vapoursynth/vapoursynth64/plugins/SourceFilter/LSmashSource/vslsmashsource.dll")
# Loading F:\TestClips&Co\test.avi using LWLibavSource
clip = core.lsmas.LWLibavSource(source="F:/TestClips&Co/test.avi", cache=0)
# adjusting color space from YUV420P8 to RGB32
clip = core.resize.Bicubic(clip=clip, format=vs.RGB, matrix_in_s="470bg")
# denoising using DGDenoise
clip = core.avs.DGDenoise(clip=clip)
# convert to YUV color space for preview
clip = core.resize.Bicubic(clip=clip, format=vs.YUV444P16)
# Output
clip.set_output()
Gave me:

Code: Select all

Python exception: Avisynth Loader: failed to load module
Traceback (most recent call last):
  File "src\cython\vapoursynth.pyx", line 1491, in vapoursynth.vpy_evaluateScript (src\cython\vapoursynth.c:26905)
  File "h:\Temp\tempPreviewVapoursynthFile19_05_15_064.vpy", line 5, in <module>
    core.avs.LoadPlugin(path="G:/Hybrid/Vapoursynth/vapoursynth64/plugins/DenoiseFilter/DGDenoise/DGDenoise.dll")
  File "src\cython\vapoursynth.pyx", line 1383, in vapoursynth.Function.__call__ (src\cython\vapoursynth.c:25212)
vapoursynth.Error: Avisynth Loader: failed to load module
thought that it should be possible to use the filter in Vapoursynth due to 'Avisynth interface version 5'.

Cu Selur

User avatar
admin
Site Admin
Posts: 4382
Joined: Thu Sep 09, 2010 3:08 pm

Re: About DGDenoise

Post by admin » Sat Aug 20, 2016 12:21 pm

Let's worry about Vapoursynth later.

Well, the error says that it can't find the file DenoiseServer.exe at this place:

G:\Hybrid\dynamic\DenoiseServer.exe

Does it live there? All the following files must be there:

DGDenoise.dll
DenoiseServer.exe
freeglut.dll
glew32.dll
cuda32_60.dll

And your script must load DGDenoise.dll from that directory. Is this all true?

I see your first script did not specify this directory so something is fishy. Is hybrid moving stuff around or some other nonsense? Also, what's up with the short filenames in your script? I can't tell if you are trying to use the plugins dir, etc. Get all the files out of the plugins dir and load DGDenoise.dll manually with all the other files in the same location. I don't know why hybrid is even involved at this point. We can try to get it working later.

Everything should work fine if you get things installed correctly.

Selur
Distinguished Member
Distinguished Member
Posts: 112
Joined: Mon Nov 05, 2012 4:49 pm

Re: About DGDenoise

Post by Selur » Sat Aug 20, 2016 12:32 pm

Does it live there?
No!

"G:\Hybrid\dynamic\avsViewer.exe" is the Viewer I use to open the Avisynth script with.
DGDenoise.dll
DenoiseServer.exe
freeglut.dll
glew32.dll
cuda32_60.dll
are all located inside the "G:\Hybrid\avisynthPlugins"-folder
(what I simply did is extract the content of the x64 folder inside the avisynthPlugins folder, which seemed like the proper way to 'install' the filter,..)

-> Seems like the filter isn't looking relative to DGDenoise.dll but relative to the viewer (or the avisynth.dll used by the viewer) for the DenoiseServer.exe.

---
the 8.3 file names are used since Avisynth can't handle unicode properly. (a lot of plugins and programs have problems if for example Chinese characters are used inside file or folder names, which why I normally stick to 8.3 filenames on Windows systems)

Cu Selur
Last edited by Selur on Sat Aug 20, 2016 1:40 pm, edited 1 time in total.

Post Reply