Log in

View Full Version : trying to test avs-mlrt


Selur
18th March 2023, 08:52
I can't get avs-mlrt working.
What I did:

create a subfolder named 'mlrt' inside my avisynthPlugins folder
extracted avs-mlrt.7z (avs-mlrt 1.0.0 from https://github.com/Asd-g/avs-mlrt/releases ) into it
extracted models.7z (avs-mlrt 1.0.0 from https://github.com/Asd-g/avs-mlrt/releases ) into it
created a onnx-subfolder inside the models folder
extracted the models from onnx-models-rd.zip (from https://forum.doom9.org/showthread.php?t=184768) into the onnx-folder.
avsresize.dll from avsresize_r21.7z into the mlrt folder
fmtconv.dll from fmtconv-r30.zip into the mlrt folder
created the following script:
ClearAutoloadDirs()
SetFilterMTMode("DEFAULT_MT_MODE", MT_MULTI_INSTANCE)
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\LSMASHSource.dll")
Import("I:\Hybrid\64bit\Avisynth\avisynthPlugins\mtmodes.avsi")

LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\x64\Release\mlrt_ncnn.dll")
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\avsresize.dll")
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\fmtconv.dll")
Import("I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\mlrt.avsi")
# loading source: G:\TestClips&Co\files\test.avi
# color sampling YV12@8, matrix: bt601, scantyp: progressive, luminance scale: limited
LWLibavVideoSource("G:\TestClips&Co\files\test.avi",cache=false,dr=true,format="YUV420P8", prefer_hw=0)
# current resolution: 640x352

#mlrt_ncnn(clip[] input, string "network_path", int "overlap_w", int "overlap_h", int "tilesize_w", int "tilesize_h", int "device_id", int "num_streams", bool "builtin", string "builtindir", bool "fp16", bool "path_is_serialization", bool "list_gpu")
ConvertBits(32)
ConvertToPlanarRGB()
mlrt_ncnn(network_path="I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\models\onnx\1x_Dotzilla_Compact_80k_net_g.onnx", builtin=false)

# setting output fps to 25.000fps
AssumeFPS(25,1)
PreFetch(2)
# output: color sampling YV12@10, matrix: bt601, scantyp: progressive, luminance scale: limited
return last
opened the script inside AVSPmod

trying to preview the script an 'Error Window' with

Traceback (most recent call last):
File "_ctypes/callbacks.c", line 315, in 'calling callback function'
File "avsp.pyo", line 6128, in local_wnd_proc
WindowsError: exception: access violation reading 0x0000000000000041
appears.
I'm running Windows 11, 64GB RAM, with an NVIDIA RTX 4080 (NVIDIA Studio-driver 528.49).
I got 'Microsoft Visual C++ 2015-2022 Redistributable (x64) - 14.32.31332' installed in my system.

when calling:
mlrt_ncnn(list_gpu=true)
it lists:

0: NVIDIA Geforce RTX 4080
1: Intel(R) Arc (TM) A380 Graphics
2: AMD Radoen(Tm) Graphics

GPU-Z reports Vulkan support for all the cards.
Using different device_ids gave the same error.

So I guessed, that the issue might be with the new onnx models or MT, using:
ClearAutoloadDirs()
#SetFilterMTMode("DEFAULT_MT_MODE", MT_MULTI_INSTANCE)
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\LSMASHSource.dll")
Import("I:\Hybrid\64bit\Avisynth\avisynthPlugins\mtmodes.avsi")

LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\x64\Release\mlrt_ncnn.dll")
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\avsresize.dll")
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\fmtconv.dll")
Import("I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\mlrt.avsi")
# loading source: G:\TestClips&Co\files\test.avi
# color sampling YV12@8, matrix: bt601, scantyp: progressive, luminance scale: limited
LWLibavVideoSource("G:\TestClips&Co\files\test.avi",cache=false,dr=true,format="YUV420P8", prefer_hw=0)
# current resolution: 640x352

#mlrt_ncnn(clip[] input, string "network_path", int "overlap_w", int "overlap_h", int "tilesize_w", int "tilesize_h", int "device_id", int "num_streams", bool "builtin", string "builtindir", bool "fp16", bool "path_is_serialization", bool "list_gpu")
ConvertBits(32)
ConvertToPlanarRGB()


mlrt_W2x()
#mlrt_ncnn(network_path="I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\models\onnx\1x_Dotzilla_Compact_80k_net_g.onnx", builtin=false)
# mlrt_ncnn(list_gpu=true)

# filtering
# Converting from 8 to 10bit for encoder
# setting output fps to 25.000fps
AssumeFPS(25,1)
#PreFetch(2)
# output: color sampling YV12@10, matrix: bt601, scantyp: progressive, luminance scale: limited
return last
that gave me:
https://i.ibb.co/xsDVyYh/grafik.png (https://ibb.co/cv1zPwJ)


My guess atm. is that I'm missing something, but I have no clue what. :(
=> Does anyone know how I can get this working? :confused:

Cu Selur

kedautinh12
18th March 2023, 09:21
Vc++ now is 14.36.32502.0
https://github.com/abbodi1406/vcredist/releases

Dogway
18th March 2023, 10:03
Not all filters work for me, actually a small subset only work in my experience, not sure if an issue with mlrt or the converted models.

Among other...

These work:
1x_Dotzilla_Compact_80k_net_g.onnx
2x_Waifaux-NL3-SuperLite_latest_G.onnx
2X_DigitalFilmV5_Lite.onnx
These don't:
scale2.0x_model.onnx
1x_NMKD-YandereInpaint_375000_G.onnx
2x_AnimeClassics_UltraLite_510K.onnx
1x_sudo_inpaint_PartialConv2D_424000_G.onnx
2x_DigitalFlim_Compact_120k_net_g.onnx
2x_DigitalFlim_SuperUltraCompact_nf24-nc8_289k_net_g.onnx

I have all plugins in default plugins64+ folder and then the models folder there

Selur
18th March 2023, 10:30
@kedautinh12: got an official link for that too? (https://learn.microsoft.com/en-us/cpp/windows/latest-supported-vc-redist?view=msvc-170 links to https://aka.ms/vs/17/release/vc_redist.x64.exe, which installs 14.34.31938)
@DogWay: 'scale2.0x_model.onnx' is one of the models that comes with avs-mlrt, so it might be an issue with avs-mlrt. I also get the error even with the models that work for you.

kedautinh12
18th March 2023, 10:56
@kedautinh12: got an official link for that too? (https://learn.microsoft.com/en-us/cpp/windows/latest-supported-vc-redist?view=msvc-170 links to https://aka.ms/vs/17/release/vc_redist.x64.exe, which installs 14.34.31938)
@DogWay: 'scale2.0x_model.onnx' is one of the models that comes with avs-mlrt, so it might be an issue with avs-mlrt. I also get the error even with the models that work for you.

Almost people at here prefer abbodi1406's ver

Selur
18th March 2023, 11:03
Almost people at here prefer abbodi1406's ver
So, that is a 'no' then. I prefer official sources for stuff that I install system-wide.:)

Cu Selur

Dogway
18th March 2023, 11:06
In case it helps this is my VCPP collection and never had a problem with any of my DCC applications, emulators and other hundreds of programs even if I don't have VCPP 2022. I don't do PC gaming though. And Win7 here.

Microsoft .NET Framework 4.8
Microsoft .NET Runtime - 5.0.1 (x64)
Microsoft Windows Desktop Runtime - 5.0.1 (x64)
VCPP 2005 Redistributable
VCPP 2005 Redistributable (x64)
VCPP 2008 Redistributable - x64 9.0.21022
VCPP 2008 Redistributable - x64 9.0.30729.17
VCPP 2008 Redistributable - x64 9.0.30729.4148
VCPP 2008 Redistributable - x64 9.0.30729.6161
VCPP 2008 Redistributable - x86 9.0.21022
VCPP 2008 Redistributable - x86 9.0.30729.17
VCPP 2008 Redistributable - x86 9.0.30729.6161
VCPP 2010 x64 Redistributable - 10.0.40219
VCPP 2010 x86 Redistributable - 10.0.40219
VCPP 2012 Redistributable (x64) - 11.0.60610
VCPP 2012 Redistributable (x64) - 11.0.61030
VCPP 2012 Redistributable (x86) - 11.0.61030
VCPP 2013 Redistributable (x64) - 12.0.30501
VCPP 2013 Redistributable (x64) - 12.0.40660
VCPP 2013 Redistributable (x86) - 12.0.30501
VCPP 2015-2019 Redistributable (x64) - 14.28.29334
VCPP 2015-2019 Redistributable (x86) - 14.23.27820

Selur
18th March 2023, 11:11
@Dogway: okay, you don't even have VC++ 2022 runtime installed, which is part of the dependencies. ¯\_(ツ)_/¯


I probably better stick with Vapoursynth for the time being.
Thanks!

Cu Selur

Dogway
18th March 2023, 11:50
Installed 2022 and looks like now it loads more models (not all though), still no go for the Waifu ones...

kedautinh12
18th March 2023, 12:00
So, that is a 'no' then. I prefer official sources for stuff that I install system-wide.:)

Cu Selur

So why don't test this ver if it's will fine?? Success only come with you if you try many time

StvG
18th March 2023, 17:20
ClearAutoloadDirs()
SetFilterMTMode("DEFAULT_MT_MODE", MT_MULTI_INSTANCE)
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\LSMASHSource.dll")
Import("I:\Hybrid\64bit\Avisynth\avisynthPlugins\mtmodes.avsi")

LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\x64\Release\mlrt_ncnn.dll")
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\avsresize.dll")
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\fmtconv.dll")
Import("I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\mlrt.avsi")
# loading source: G:\TestClips&Co\files\test.avi
# color sampling YV12@8, matrix: bt601, scantyp: progressive, luminance scale: limited
LWLibavVideoSource("G:\TestClips&Co\files\test.avi",cache=false,dr=true,format="YUV420P8", prefer_hw=0)
# current resolution: 640x352

#mlrt_ncnn(clip[] input, string "network_path", int "overlap_w", int "overlap_h", int "tilesize_w", int "tilesize_h", int "device_id", int "num_streams", bool "builtin", string "builtindir", bool "fp16", bool "path_is_serialization", bool "list_gpu")
ConvertBits(32)
ConvertToPlanarRGB()
mlrt_ncnn(network_path="I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\models\onnx\1x_Dotzilla_Compact_80k_net_g.onnx", builtin=false)

# setting output fps to 25.000fps
AssumeFPS(25,1)
PreFetch(2)
# output: color sampling YV12@10, matrix: bt601, scantyp: progressive, luminance scale: limited
return last

I tested this model and I have no issues. Also the latest comment is weird "# output: color sampling YV12@10, matrix: bt601, scantyp: progressive, luminance scale: limited" - the output of mlrt_ncnn is not YV12@10.

ClearAutoloadDirs()
#SetFilterMTMode("DEFAULT_MT_MODE", MT_MULTI_INSTANCE)
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\LSMASHSource.dll")
Import("I:\Hybrid\64bit\Avisynth\avisynthPlugins\mtmodes.avsi")

LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\x64\Release\mlrt_ncnn.dll")
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\avsresize.dll")
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\fmtconv.dll")
Import("I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\mlrt.avsi")
# loading source: G:\TestClips&Co\files\test.avi
# color sampling YV12@8, matrix: bt601, scantyp: progressive, luminance scale: limited
LWLibavVideoSource("G:\TestClips&Co\files\test.avi",cache=false,dr=true,format="YUV420P8", prefer_hw=0)
# current resolution: 640x352

#mlrt_ncnn(clip[] input, string "network_path", int "overlap_w", int "overlap_h", int "tilesize_w", int "tilesize_h", int "device_id", int "num_streams", bool "builtin", string "builtindir", bool "fp16", bool "path_is_serialization", bool "list_gpu")
ConvertBits(32)
ConvertToPlanarRGB()


mlrt_W2x()
#mlrt_ncnn(network_path="I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\models\onnx\1x_Dotzilla_Compact_80k_net_g.onnx", builtin=false)
# mlrt_ncnn(list_gpu=true)

# filtering
# Converting from 8 to 10bit for encoder
# setting output fps to 25.000fps
AssumeFPS(25,1)
#PreFetch(2)
# output: color sampling YV12@10, matrix: bt601, scantyp: progressive, luminance scale: limited
return last

I suggest to read carefully mlrt.avsi - # Folder "models" must be in the same location as avs-mlrt. (https://github.com/Asd-g/avs-mlrt/blob/main/mlrt.avsi#L51).

Installed 2022 and looks like now it loads more models (not all though), still no go for the Waifu ones...

What does this mean? Is it wrong path, is it wrong output, is it crashing? Did you try "mlrt_ncnn(...., tilesize_w=Width()/2, tilesize_h=Height()/2)"?

Dogway
18th March 2023, 18:25
What does this mean? Is it wrong path, is it wrong output, is it crashing? Did you try "mlrt_ncnn(...., tilesize_w=Width()/2, tilesize_h=Height()/2)"?

Basically freezes AvsPmod. I tested with:
mlrt_ncnn(network_path="C:\Program Files (x86)\AviSynth+\plugins64+\models\waifu2x-ONNX\anime_style_art\scale2.0x_model.onnx", builtin=false, tilesize_w=Width()/2, tilesize_h=Height()/2)

And freezed. But just to be sure I checked also with:
mlrt_W2x(-1,1,1)

And worked. I presume is equivalent to the above model call but with different arguments.

Reel.Deel
18th March 2023, 20:16
Not all filters work for me, actually a small subset only work in my experience, not sure if an issue with mlrt or the converted models.

Among other...

These work:
1x_Dotzilla_Compact_80k_net_g.onnx
2x_Waifaux-NL3-SuperLite_latest_G.onnx
2X_DigitalFilmV5_Lite.onnx
These don't:
scale2.0x_model.onnx
1x_NMKD-YandereInpaint_375000_G.onnx
2x_AnimeClassics_UltraLite_510K.onnx
1x_sudo_inpaint_PartialConv2D_424000_G.onnx
2x_DigitalFlim_Compact_120k_net_g.onnx
2x_DigitalFlim_SuperUltraCompact_nf24-nc8_289k_net_g.onnx

I have all plugins in default plugins64+ folder and then the models folder there

I tried 2x_AnimeClassics_UltraLite_510K.onnx and it just hangs for me :confused:. Usually the UltraLite models work fine on my crappy GPU.

poisondeathray
18th March 2023, 20:28
I tried 2x_AnimeClassics_UltraLite_510K.onnx and it just hangs for me :confused:. Usually the UltraLite models work fine on my crappy GPU.

Memory issue again ? Did you try tiles ?

Works for me , an a locally converted version . I downloaded from your dropbox, and it works too . For some reason there is a filesize difference in the onnx conversion . Yours was 7.79MB, mine was 7.85MB. I couldn't see any difference when testing a few frames

Reel.Deel
18th March 2023, 20:36
Memory issue again ? Did you try tiles ?

Works for me , an a locally converted version . I downloaded from your dropbox, and it works too . For some reason there is a filesize difference in the onnx conversion . Yours was 7.79MB, mine was 7.85MB. I couldn't see any difference when testing a few frames

I tried tilesize_w=width/4, tilesize_h=height/4, overlap_w=8, overlap_h=8 and still just hangs.

I tested the onnx model in Chainner and it works there also (albeit, much slower than the pth model).

https://i.ibb.co/zr4Zh6P/chainner-onnx.png

poisondeathray
18th March 2023, 20:40
No error message ? Just "hangs" ?

Yet other onnx conversions work ok on that same avs setup ?

Did you check that other applications which might be using GPU are closed ?

Selur
18th March 2023, 22:04
I suggest to read carefully mlrt.avsi - # Folder "models" must be in the same location as avs-mlrt..
All the models that mlrt.avsi are in a models folder, which is next to mlrt.avsi.
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\avsresize.dll
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\fmtconv.dll
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\LICENSE
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\mlrt.avsi
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\README.md
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\x64
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\dpir
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\RealESRGANv2
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\pro-conservative-up2x.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\pro-conservative-up3x.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\pro-denoise3x-up2x.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\pro-denoise3x-up3x.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\pro-no-denoise3x-up2x.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\pro-no-denoise3x-up3x.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\up2x-latest-conservative.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\up2x-latest-denoise1x.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\up2x-latest-denoise2x.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\up2x-latest-denoise3x.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\up2x-latest-no-denoise.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\up3x-latest-conservative.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\up3x-latest-denoise3x.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\up3x-latest-no-denoise.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\up4x-latest-conservative.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\up4x-latest-denoise3x.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\cugan\up4x-latest-no-denoise.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\dpir\drunet_color.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\dpir\drunet_deblocking_color.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\dpir\drunet_deblocking_grayscale.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\dpir\drunet_gray.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x-Kim2091_DeJpeg.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1xBaldrickVHSFix_180000_G_V0.2.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_AnimeUndeint_Compact_130k_net_g.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_BleedOut_Compact_300k_net_g.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_BroadcastToStudioLite_485k.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_Debandurh_FS_lite_140000_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_DeBLR.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_DitherDeleterV3-Smooth-[32]_115000_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_Dotzilla_Compact_80k_net_g.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_Dotzilla_SuperUltraCompact_300k_net_g.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_Dotzilla_UltraCompact_182k_net_g.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_Fatality_DeBlur_270000_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_Filmify4K_v2_325000_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_GainRESV3_Aggro.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_GainRESV3_Natural.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_GainRESV3_Passive.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_HurrDeblur_SuperUltraCompact_nf24-nc8_244k_net_g.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_ISO_denoise_v2.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_JPEG_00-20.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_JPEG_20-40.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_JPEG_40-60.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_JPEG_60-80.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_JPEG_80-100.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_MangaJPEGHQ.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_MangaJPEGHQPlus.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_MangaJPEGLQ.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_MangaJPEGMQ.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_mdeblur.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_NMKD-YandereInpaint_375000_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_sudo_inpaint_PartialConv2D_424000_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_SwatKatsLite_360000_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_ThePi7on-Solidd_Deborutify_UltraLite_260k_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\1x_UnResize_V3_200000_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\2x_AnimeClassics_UltraLite_510K.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\2x_BIGOLDIES_415000_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\2X_DigitalFilmV5_Lite.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\2x_DigitalFlim_Compact_120k_net_g.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\2x_DigitalFlim_SuperUltraCompact_nf24-nc8_289k_net_g.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\2x_Futsuu_Anime_Compact_130k_net_g.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\2x_LD-Anime_Compact_330k_net_g.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\2x_LD-Anime_Skr_v1.0.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\2x_Waifaux-NL3-SuperLite_latest_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\4x-UniScaleV2_Moderate.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\4x-UniScaleV2_Sharp.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\4x-UniScaleV2_Soft.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\4x_eula_digimanga_bw_v1_860k.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\4x_eula_digimanga_bw_v2_nc1_307k.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\4x_Valar_v1.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\ToonVHS-1x-300000_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\onnx\VHS-Sharpen-1x_46000_G.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\RealESRGANv2\realesr-animevideov3.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\RealESRGANv2\RealESRGANv2-animevideo-xsx2.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\RealESRGANv2\RealESRGANv2-animevideo-xsx4.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\anime_style_art
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\anime_style_art_rgb
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\cunet
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\photo
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\ukbench
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upconv_7_anime_style_art_rgb
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upconv_7_photo
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upresnet10
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\anime_style_art\noise1_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\anime_style_art\noise2_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\anime_style_art\noise3_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\anime_style_art\scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\anime_style_art_rgb\noise0_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\anime_style_art_rgb\noise1_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\anime_style_art_rgb\noise2_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\anime_style_art_rgb\noise3_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\anime_style_art_rgb\scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\cunet\noise0_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\cunet\noise0_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\cunet\noise1_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\cunet\noise1_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\cunet\noise2_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\cunet\noise2_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\cunet\noise3_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\cunet\noise3_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\cunet\scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\photo\noise0_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\photo\noise1_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\photo\noise2_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\photo\noise3_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\photo\scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\ukbench\scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upconv_7_anime_style_art_rgb\noise0_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upconv_7_anime_style_art_rgb\noise1_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upconv_7_anime_style_art_rgb\noise2_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upconv_7_anime_style_art_rgb\noise3_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upconv_7_anime_style_art_rgb\scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upconv_7_photo\noise0_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upconv_7_photo\noise1_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upconv_7_photo\noise2_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upconv_7_photo\noise3_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upconv_7_photo\scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upresnet10\noise0_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upresnet10\noise1_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upresnet10\noise2_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upresnet10\noise3_scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\models\waifu2x\upresnet10\scale2.0x_model.onnx
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\x64\Release
I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\x64\Release\mlrt_ncnn.dll

I also tried whether it makes a difference moving mlrt_ncnn.dll to the mlrt folder and thus using:
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\mlrt_ncnn.dll")
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\avsresize.dll")
LoadPlugin("I:\Hybrid\64bit\Avisynth\AVISYN~1\mlrt\fmtconv.dll")
Import("I:\Hybrid\64bit\Avisynth\avisynthPlugins\mlrt\mlrt.avsi")

still causes avspmod to freeze and give me:

Traceback (most recent call last):
File "_ctypes/callbacks.c", line 315, in 'calling callback function'
File "avsp.pyo", line 6128, in local_wnd_proc
WindowsError: exception: access violation reading 0x0000000000000041


waifu2x and all the other filters run fine in Vapoursynth for me.
When using a 640x352 source I don't need to use tiling for any of them. (my card has 16gb ram, which is enought for sd content in RGBS, so tiling should not be needed.)

Could this be related to my CPU ? (I'm using Ryzen 9 7950X) Does avs-mlrt only work with Intel CPUs?

Cu Selur

StvG
18th March 2023, 22:47
Basically freezes AvsPmod. I tested with:
mlrt_ncnn(network_path="C:\Program Files (x86)\AviSynth+\plugins64+\models\waifu2x-ONNX\anime_style_art\scale2.0x_model.onnx", builtin=false, tilesize_w=Width()/2, tilesize_h=Height()/2)

And freezed. But just to be sure I checked also with:
mlrt_W2x(-1,1,1)

And worked. I presume is equivalent to the above model call but with different arguments.

"mlrt_W2x(-1,1,1)" is the same as
mlrt_ncnn("....\scale2.0x_model.onnx", fp16=true, builtin=false)
fmtc_resample(scale=0.5, kernel="impulse", impulse=[-0.1875, 1.375, -0.1875], kovrspl=2)

All the models that mlrt.avsi are in a models folder, which is next to mlrt.avsi.

"models" folder should be next to mlrt_ncnn.dll. The location of "mlrt.avsi" doesn't matter.

waifu2x and all the other filters run fine in Vapoursynth for me.
When using a 640x352 source I don't need to use tiling for any of them. (my card has 16gb ram, which is enought for sd content in RGBS, so tiling should not be needed.)

Could this be related to my CPU ? (I'm using Ryzen 9 7950X) Does avs-mlrt only work with Intel CPUs?

Cu Selur

Try update the GPU drivers to the latest if you don't have them already.

Selur
18th March 2023, 22:48
Okay, I found the issue.
I was using the last stable Avisynth+ version from https://github.com/AviSynth/AviSynthPlus/releases (3.7.2)
after updating to 3.7.3 r3958 from https://gitlab.com/uvz/AviSynthPlus-Builds/-/tree/main/Clang/x64/plugins it seems to work.


So my issue was me, stupidly overlooking that a non-stable, non-official release was a requirement for avs-mrlt.


Cu Selur

Ps.: personally, I'll wait after the next official release before I test this further.