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 > Avisynth Development

Reply
 
Thread Tools Search this Thread Display Modes
Old 23rd July 2020, 19:56   #21  |  Link
DTL
Registered User
 
Join Date: Jul 2018
Posts: 35
Strange to see Lanczos resize as reference for video data. I think the SincResize (with max possible 'taps' parameter) is closer to reference upsize resampler for band-limited and 'conditioned' against ringing good quality video data. Lanczos is more universal, but it significally limited for reference restoring of highset frequencies in video data. Unfortunately current version avisynth looks like has (small) bug in SincResize resampler implementation and it can make compare metrics with ideal input reference image data worse.
DTL is offline   Reply With Quote
Old 25th July 2020, 21:35   #22  |  Link
Alexkral
Registered User
 
Join Date: Oct 2018
Posts: 230
AviSynth AiUpscale v1.0.1

Changes:

- Added shaders source code.
- Some minor fixes.
Alexkral is offline   Reply With Quote
Old 26th July 2020, 19:23   #23  |  Link
wolfman2791
Registered User
 
wolfman2791's Avatar
 
Join Date: Jan 2014
Posts: 63
This is very good. Thank you!
wolfman2791 is offline   Reply With Quote
Old 27th July 2020, 03:12   #24  |  Link
gmail123
Registered User
 
Join Date: Dec 2014
Posts: 23
how to import to vs?
gmail123 is offline   Reply With Quote
Old 27th July 2020, 05:22   #25  |  Link
Alexkral
Registered User
 
Join Date: Oct 2018
Posts: 230
Quote:
Originally Posted by wolfman2791 View Post
This is very good. Thank you!
You're welcome.
Quote:
Originally Posted by gmail123 View Post
how to import to vs?
I'm pretty new to VapourSynth so I can't help you with that, sorry.
Alexkral is offline   Reply With Quote
Old 27th July 2020, 05:49   #26  |  Link
poisondeathray
Registered User
 
Join Date: Sep 2007
Posts: 4,389
Quote:
Originally Posted by gmail123 View Post
how to import to vs?
you can run glsl shaders directly in vs with vs-placebo

https://github.com/Lypheo/vs-placebo


If you're on Windows with avisynth installed, you can also import an avs script into vapoursynth with AVISource
poisondeathray is offline   Reply With Quote
Old 27th July 2020, 08:46   #27  |  Link
gmail123
Registered User
 
Join Date: Dec 2014
Posts: 23
Quote:
Originally Posted by poisondeathray View Post
you can run glsl shaders directly in vs with vs-placebo

https://github.com/Lypheo/vs-placebo


If you're on Windows with avisynth installed, you can also import an avs script into vapoursynth with AVISource
my english is poor...
sample:1080p ---->2160P,
can you give me a vs script ?
thx!
gmail123 is offline   Reply With Quote
Old 27th July 2020, 14:44   #28  |  Link
poisondeathray
Registered User
 
Join Date: Sep 2007
Posts: 4,389
Quote:
Originally Posted by gmail123 View Post
my english is poor...
sample:1080p ---->2160P,
can you give me a vs script ?
thx!

My English is poor too (and it's my first language )


You should probably post in the vapoursynth subforum

One difference is Alexral did some separate training (slightly different) . I'm not sure how to use those into vapoursynth directly; only .glsl shaders can be used with placebo.Shader . (You can use the AVISource workaround, but you need windows, avisynth installed)

There is documentation on the page


eg.

Code:
import vapoursynth as vs
core = vs.get_core()
clip = core.lsmas.LWLibavSource(r'PATH\input.mkv')
clip = core.resize.Bicubic(clip, format=vs.YUV444P16)
clip = core.placebo.Shader(clip, width=clip.width*2, height=clip.height*2, shader=r'PATH\FSRCNN-Medium\FSRCNN_x2_r2_16-0-2.glsl')
clip.set_output()

Last edited by poisondeathray; 28th July 2020 at 19:51. Reason: "LWLibavSource" for mkv example , oops
poisondeathray is offline   Reply With Quote
Old 27th July 2020, 16:15   #29  |  Link
Alexkral
Registered User
 
Join Date: Oct 2018
Posts: 230
Yes, there are no glsl mpv hooks of the VDSR and HQ models because they were fully or partially trained with Matlab, and their weights were converted directly to hlsl. They would have been too slow for mpv anyway.
Alexkral is offline   Reply With Quote
Old 28th July 2020, 11:38   #30  |  Link
biship
Registered User
 
Join Date: Feb 2012
Posts: 17
This can be used in MadVR?
__________________
LG OLED65C9PUA | Denon AVR-X3500H | Windows 10 | NVIDIA GeForce GTX 1050 | LAV Filters | madVR | MediaPortal | Plex
biship is offline   Reply With Quote
Old 28th July 2020, 13:15   #31  |  Link
Alexkral
Registered User
 
Join Date: Oct 2018
Posts: 230
Quote:
Originally Posted by biship View Post
This can be used in MadVR?
No, they are different programs.
Alexkral is offline   Reply With Quote
Old 30th July 2020, 17:34   #32  |  Link
gmail123
Registered User
 
Join Date: Dec 2014
Posts: 23
compare to with Waifu2x- cunet (For 2D artwork. Slow, but better quality.)?
gmail123 is offline   Reply With Quote
Old 31st July 2020, 02:04   #33  |  Link
Alexkral
Registered User
 
Join Date: Oct 2018
Posts: 230
Quote:
Originally Posted by gmail123 View Post
compare to with Waifu2x- cunet (For 2D artwork. Slow, but better quality.)?
That's subjective. For RGB it seems that the VDSR and HQ models are a little slower. Looking at the results, I think you'll find that the AiUpscale models are a bit sharper.
Alexkral is offline   Reply With Quote
Old 31st July 2020, 02:43   #34  |  Link
gmail123
Registered User
 
Join Date: Dec 2014
Posts: 23
Quote:
Originally Posted by Alexkral View Post
That's subjective. For RGB it seems that the VDSR and HQ models are a little slower. Looking at the results, I think you'll find that the AiUpscale models are a bit sharper.
I had tested it,VDSR/HQ models are very good.

1、Plan to support 32bit float?
2、for video, "Photo" or "Illustration",Which is better?
gmail123 is offline   Reply With Quote
Old 31st July 2020, 03:19   #35  |  Link
Alexkral
Registered User
 
Join Date: Oct 2018
Posts: 230
32 bit float is not supported because the processing in Avisynth Shader is done at 16 bit depth, I don't think that will change.

For video that comes from a camera you should use the "Photo" models, the "Illustration" models are for artwork, drawings, etc.
Alexkral is offline   Reply With Quote
Old 31st July 2020, 03:30   #36  |  Link
gmail123
Registered User
 
Join Date: Dec 2014
Posts: 23
Quote:
Originally Posted by Alexkral View Post
32 bit float is not supported because the processing in Avisynth Shader is done at 16 bit depth, I don't think that will change.

For video that comes from a camera you should use the "Photo" models, the "Illustration" models are for artwork, drawings, etc.
good,thx!
gmail123 is offline   Reply With Quote
Old 31st July 2020, 07:57   #37  |  Link
markiemarcus
Registered User
 
Join Date: May 2018
Posts: 48
This is really fantastic work. Thank you so much for all of the effort! These NN upscalers can be a little unpredictable and being able to modify the script and check the results in realtime is just invaluable. Really, really, terrific work. It's incredibly fast, too. Absolutely flies on my RX 480.
markiemarcus is offline   Reply With Quote
Old 31st July 2020, 09:39   #38  |  Link
markiemarcus
Registered User
 
Join Date: May 2018
Posts: 48
Quick question. How is this handling 601 to 709 conversion, if at all? The SD sources I'm working from are all 601 so there's a huge shift post upscale. Is there an optimal way of handling this?
markiemarcus is offline   Reply With Quote
Old 31st July 2020, 11:26   #39  |  Link
Alexkral
Registered User
 
Join Date: Oct 2018
Posts: 230
Quote:
Originally Posted by markiemarcus View Post
Quick question. How is this handling 601 to 709 conversion, if at all? The SD sources I'm working from are all 601 so there's a huge shift post upscale. Is there an optimal way of handling this?
Hi, thanks for the feedback. There is no conversion between RGB and YUV so there should be no change in this. If you're using VirtualDub2 you have to select that in Video > Decode format.
Alexkral is offline   Reply With Quote
Old 31st July 2020, 20:22   #40  |  Link
markiemarcus
Registered User
 
Join Date: May 2018
Posts: 48
Quote:
Originally Posted by Alexkral View Post
Hi, thanks for the feedback. There is no conversion between RGB and YUV so there should be no change in this. If you're using VirtualDub2 you have to select that in Video > Decode format.
Spot on, thanks for getting back to me. Again, this is just fab work and much appreciated.
markiemarcus 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 02:44.


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