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 > VapourSynth

Reply
 
Thread Tools Search this Thread Display Modes
Old 6th October 2023, 15:16   #161  |  Link
ReinerSchweinlin
Registered User
 
Join Date: Oct 2001
Posts: 454
Sorry, I canīt help, thats beyond my capabilities

But I just wanted to say "thanks" for all you do !!
ReinerSchweinlin is offline   Reply With Quote
Old 20th October 2023, 21:08   #162  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
btw. did anyone test NNVISR ? (https://github.com/tongyuantongyu/vs-NNVISR)
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 21st October 2023, 02:50   #163  |  Link
lansing
Registered User
 
Join Date: Sep 2006
Posts: 1,657
Quote:
Originally Posted by Selur View Post
btw. did anyone test NNVISR ? (https://github.com/tongyuantongyu/vs-NNVISR)
I couldn't get it working on vsedit2 or vd2 or vsedit_mod. I manual install the plugin and its dependencies. Somehow the plugin won't auto load when I put it in my roaming folder, so I'll have to put everything in Vapoursynth's installation plugin folder. But everything just crashed after some loading time.

Code:
import vapoursynth as vs

core = vs.core

clip = core.bs.VideoSource(r'E:\video samples\hand wave.mkv')

model_config = {'scale_factor': 2, 'input_count': 2, 'feature_count': 64, 'extraction_layers': 4, 'interpolation': True, 'extra_frame': True, 'double_frame': True, 'model': 'cycmunet/vimeo90k-deblur'}

clip = core.nnvisr.Super(clip,
                         model_path=r"C:\Program Files\VapourSynth\plugins",  **model_config)

clip.set_output()
lansing is offline   Reply With Quote
Old 21st October 2023, 06:33   #164  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
When I first tested this, I used this file structure
Code:
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\cublas64_12.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\cublasLt64_12.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\cudart64_12.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\cudnn64_8.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\cudnn_adv_infer64_8.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\cudnn_adv_train64_8.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\cudnn_cnn_infer64_8.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\cudnn_cnn_train64_8.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\cudnn_ops_infer64_8.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\cudnn_ops_train64_8.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\models
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\nvblas64_12.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\nvinfer.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\nvinfer_builder_resource.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\nvinfer_dispatch.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\nvinfer_lean.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\nvinfer_plugin.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\nvinfer_vc_plugin.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\nvonnxparser.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\nvrtc-builtins64_121.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\nvrtc64_120_0.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\test_1.vpy
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\timing.cache
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\vs-nnvisr.dll
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\8601
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\cycmunet
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\8601\NVIDIA GeForce RTX 4080
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\8601\NVIDIA GeForce RTX 4080\cycmunet
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\8601\NVIDIA GeForce RTX 4080\timing.cache
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\8601\NVIDIA GeForce RTX 4080\cycmunet\vimeo90k-deblur
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\8601\NVIDIA GeForce RTX 4080\cycmunet\vimeo90k-deblur\yuv_1_1_1
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\8601\NVIDIA GeForce RTX 4080\cycmunet\vimeo90k-deblur\yuv_1_1_1\fe_640x352_2x2_b1_l4_yuv1-1.engine
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\8601\NVIDIA GeForce RTX 4080\cycmunet\vimeo90k-deblur\yuv_1_1_1\ff_n2a+_640x352_2x2_b1_l4_yuv1-1.engine
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\cycmunet\vimeo90k-deblur
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\cycmunet\vimeo90k-deblur\yuv_1_1_1
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\cycmunet\vimeo90k-deblur\yuv_1_1_1\fe_640x352_2x2_b1_l4_yuv1-1.engine
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\engines\cycmunet\vimeo90k-deblur\yuv_1_1_1\ff_n2a+_640x352_2x2_b1_l4_yuv1-1.engine
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\models\cycmunet
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\models\yogo
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\models\cycmunet\vimeo90k-deblur
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\models\cycmunet\vimeo90k-deblur\yuv_1_1_1
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\models\cycmunet\vimeo90k-deblur\yuv_1_1_1\fe_n2_2x2_l4_yuv1-1.onnx
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\models\cycmunet\vimeo90k-deblur\yuv_1_1_1\ff_n2_2x2_l4_yuv1-1.onnx
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\models\yogo\vimeo90k
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\models\yogo\vimeo90k\rgb_1_1
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\models\yogo\vimeo90k\rgb_1_1\fe_n4_4x4_l1.onnx
F:\Hybrid\64bit\vsfilters\ResizeFilter\NNVISR\models\yogo\vimeo90k\rgb_1_1\ff_n4_4x4_l1.onnx
and the following script:
Code:
# Imports
import vapoursynth as vs
# getting Vapoursynth core
core = vs.core
import site
import os
import ctypes
# Adding torch dependencies to PATH
path = site.getsitepackages()[0]+'/../vsfilters/ResizeFilter/NNVISR'
ctypes.windll.kernel32.SetDllDirectoryW(path)
path = path.replace('\\', '/')
os.environ["PATH"] = path + os.pathsep + os.environ["PATH"]


# Loading Plugins
core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/SourceFilter/LSmashSource/vslsmashsource.dll")
core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/ResizeFilter/NNVISR/vs-nnvisr.dll")

# source: 'G:\TestClips&Co\files\test.avi'
# current color space: YUV420P8, bit depth: 8, resolution: 640x352, fps: 25, color matrix: 470bg, yuv luminance scale: limited, scanorder: progressive
# Loading G:\TestClips&Co\files\test.avi using LWLibavSource
clip = core.lsmas.LWLibavSource(source="G:/TestClips&Co/files/test.avi", format="YUV420P8", stream_index=0, cache=0, prefer_hw=0)

# Setting detected color matrix (470bg).
clip = core.std.SetFrameProps(clip, _Matrix=5)
# Setting color transfer info (470bg), when it is not set
clip = clip if not core.text.FrameProps(clip,'_Transfer') else core.std.SetFrameProps(clip, _Transfer=5)
# Setting color primaries info (), when it is not set
clip = clip if not core.text.FrameProps(clip,'_Primaries') else core.std.SetFrameProps(clip, _Primaries=5)
# Setting color range to TV (limited) range.
clip = core.std.SetFrameProp(clip=clip, prop="_ColorRange", intval=1)
# making sure frame rate is set to 25
clip = core.std.AssumeFPS(clip=clip, fpsnum=25, fpsden=1)
clip = core.std.SetFrameProp(clip=clip, prop="_FieldBased", intval=0) # progressive

clip = core.resize.Bicubic(clip=clip, matrix_in_s="470bg", matrix_s="709", range_in=0, range=0) # converting to bt709 for NNVISR
clip = core.std.SetFrameProps(clip, _Transfer=1)
clip = core.std.SetFrameProps(clip, _Primaries=1)

model_config = {'scale_factor': 2, 'input_count': 2, 'feature_count': 64, 'extraction_layers': 4, 'interpolation': True, 'extra_frame': True, 'double_frame': True, 'model': 'cycmunet/vimeo90k-deblur'}
clip = core.nnvisr.Super(clip, model_path="F:/Hybrid/64bit/vsfilters/ResizeFilter/NNVISR", **model_config)

# Output
clip.set_output()
in a portable Vapoursynth setup. But I had my struggles too (https://github.com/tongyuantongyu/vs-NNVISR/issues/2).
Maybe this helps you getting it working.

Cu Selur

Ps.: iirc. it took ages to get engine files created on my setup when I tested it.
__________________
Hybrid here in the forum, homepage

Last edited by Selur; 21st October 2023 at 06:47.
Selur is offline   Reply With Quote
Old 26th November 2023, 10:01   #165  |  Link
julius666
Registered User
 
julius666's Avatar
 
Join Date: May 2009
Location: Hungary
Posts: 79
Does anyone know what happened to vs-femasr? The github repository is not available anymore.
julius666 is offline   Reply With Quote
Old 26th November 2023, 11:00   #166  |  Link
kedautinh12
Registered User
 
Join Date: Jan 2018
Posts: 2,156
HolyWu was deleted it (maybe)

Last edited by kedautinh12; 26th November 2023 at 12:22.
kedautinh12 is offline   Reply With Quote
Old 26th November 2023, 14:06   #167  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
Yup, like a few other repos HolyWu deleted it. (or set it private)
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 1st December 2023, 17:52   #168  |  Link
julius666
Registered User
 
julius666's Avatar
 
Join Date: May 2009
Location: Hungary
Posts: 79
Quote:
Originally Posted by Selur View Post
Yup, like a few other repos HolyWu deleted it. (or set it private)
I thought so but do we have any information regarding why he did that? It was one of the best (if not THE best) upscalers in vapoursynth.
julius666 is offline   Reply With Quote
Old 1st December 2023, 18:25   #169  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
No (at least not that I know of), you would have to ask him (maybe by posting an issue in one of this other projects https://github.com/HolyWu/).
Probably because there hasn't been an update to it, not much feedback and keeping it working with latest pytorch&co was too much trouble.
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 2nd December 2023, 15:55   #170  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
btw. for those who need colorization of b&w content https://github.com/HolyWu/vs-ddcolor might be worth a try:

did some small tests which do seem good so far.

Cu Selur
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 2nd December 2023, 17:51   #171  |  Link
kedautinh12
Registered User
 
Join Date: Jan 2018
Posts: 2,156
Wow, respect HolyWu
kedautinh12 is offline   Reply With Quote
Old 2nd December 2023, 19:54   #172  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
https://github.com/piddnad/DDColor should get the main respect, HolyWu 'just' wrote a Vapoursynth Wrapper for it.
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 3rd December 2023, 01:57   #173  |  Link
kedautinh12
Registered User
 
Join Date: Jan 2018
Posts: 2,156
Ok, piddnad too
kedautinh12 is offline   Reply With Quote
Old 17th January 2024, 20:43   #174  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
Anyone has an idea how to stabilize the colorization output of ddcolor? (see: https://forum.selur.net/thread-3532.html)
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 2nd March 2024, 13:54   #175  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
https://github.com/dan64/vs-deoldify might be interesting for those interested in colorization
__________________
Hybrid here in the forum, homepage

Last edited by Selur; 2nd March 2024 at 14:48.
Selur is offline   Reply With Quote
Old 4th March 2024, 12:06   #176  |  Link
ReinerSchweinlin
Registered User
 
Join Date: Oct 2001
Posts: 454
Thank you.

I have a somewhat amateur question:

If this is based on pytorch - what relevance does the used GPU have in this case? Some hybrid filters are clearly based on specific stuff like vulkan or CUDA (CDNN) or some other filters use OPENCL... How does it work here?

I have been playing around with some StableDiffusion GUIs and here It seems (as far as I understand it), all that needs to be modified is how Pytorch passes the calls from the GUI to the underlying inferences. So if I want to use DirectML, I need the py-directML stuff, if i have Nvidia, I stick to the tensorRT or CUDA, hence must install pytor...cuda... etc... So basically, as long as some backend in pytorch for my specific hardware exists, the filter itself will run...

Could you help straighten out my somewhat fuzzy thinking of how it is related ?

Thanx
ReinerSchweinlin is offline   Reply With Quote
Old 4th March 2024, 16:06   #177  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
afaik vs-deoldify uses cudnn as backend (see: https://github.com/dan64/vs-deoldify...ify/_device.py)
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 5th March 2024, 12:21   #178  |  Link
ReinerSchweinlin
Registered User
 
Join Date: Oct 2001
Posts: 454
Quote:
Originally Posted by Selur View Post
afaik vs-deoldify uses cudnn as backend (see: https://github.com/dan64/vs-deoldify...ify/_device.py)
Thanx for pointing me in the right direction
ReinerSchweinlin is offline   Reply With Quote
Old 9th March 2024, 17:59   #179  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
Side note for those using tensorrt: atm. there isn't a Python 3.12 version of the bindings (tensorrt-8.6.1-cp311-none-win_amd64.whl is the latest currently), so switching to Vapoursynth R66 will not work.

Cu Selur
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 11th March 2024, 17:45   #180  |  Link
PatchWorKs
Registered User
 
PatchWorKs's Avatar
 
Join Date: Aug 2002
Location: Italy
Posts: 304
Just out of curiosity: does anyone tested vs-mlrt performances on Intel CPU+iGPU ?
__________________
Hybrid Multimedia Production Suite will be a platform-indipendent open source suite for advanced audio/video contents production.

Official git: https://www.forart.it/HyMPS/
PatchWorKs 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 17:22.


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