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. |
20th May 2019, 15:41 | #521 | Link |
Registered User
Join Date: Feb 2014
Posts: 355
|
Hello, and thank you jpsdr for your hard work . I'm preparing to upscale my PAL Futurama DVD's to 960x720 and found this:
Code:
### Resize ### NNEDI3_RPow2(RFactor=2,CShift="Spline64Resize",FWidth=960,FHeight=720) aWarpSharp2(Depth=5) Sharpen(0.2) Code:
### Overall Temporal Denoise ### SMDegrain(TR=2,ThSAD=200,ContraSharp=True,RefineMotion=True,Plane=0,PreFilter=2,Chroma=False,LSB=True,LSB_Out=True)### Resize ### NNEDI3_RPow2(RFactor=2,CShift="Spline64Resize",FWidth=960,FHeight=720) aWarpSharp2(Depth=5) Sharpen(0.2) Edit: I just noticed that this thread hasn't seen action in almost a year; however, if anyone can answer my question I'd be very appreciative. Last edited by LouieChuckyMerry; 20th May 2019 at 15:42. Reason: Date |
20th May 2019, 17:07 | #522 | Link |
Registered User
Join Date: Jul 2012
Posts: 1,213
|
Your source filter might be stacking in order to give you a 16 bit pipeline.
At conclusion of workflow when the "8 over 8" is undone you get half height resolution Try a quick sample with resize of 960 x 1440 or get a better source filter if possible |
20th May 2019, 19:26 | #523 | Link |
Registered User
Join Date: Feb 2014
Posts: 355
|
Thanks for your reply, gonca. My source filter is DGIndexNV for the .m2v video. I know that SMDegrain stacks the video then sends stacked 16-bit to NNEDI3, but it seems NNEDI3 isn't happy about this. I'm using the latest AviSynth+. Let me try a quick resize... That actually worked, but is it the correct way or is there some AviSynth+ syntax I'm missing?
Edit: I indexed with LSMASH and it's the same story, 960x360 output. Hmmm... Last edited by LouieChuckyMerry; 20th May 2019 at 19:34. |
20th May 2019, 21:34 | #524 | Link | |
Registered User
Join Date: Jul 2012
Posts: 1,213
|
DGIndexNV is fine and not the problem
Can you give DGDenoise a try instead of using SMDegrain or use Quote:
after SMDegrain |
|
20th May 2019, 23:16 | #525 | Link | ||
Registered User
Join Date: Feb 2014
Posts: 355
|
Quote:
Quote:
Code:
### Overall Temporal Denoise ### SMDegrain(TR=2,ThSAD=200,ContraSharp=True,RefineMotion=True,Plane=0,PreFilter=2,Chroma=False,LSB=True,LSB_Out=True) ### Resize ### NNEDI3_RPow2(RFactor=2,CShift="Spline64Resize",FWidth=960,FHeight=720) aWarpSharp2(Depth=5) Sharpen(0.2) ### Darken-Thin Lines ### F=DitherPost(Mode=-1) S=F.FastLineDarkenMod(Strength=24,Prot=6).aWarpSharp2(Blur=4,Type=1,Depth=8,Chroma=2) D=MT_MakeDiff(S,F).Dither_Convert_8_To_16() Dither_Add16(Last,D,Dif=True,U=2,V=2) ### Deband ### F3KDB(Y=100,Cb=100,Cr=100,GrainY=0,GrainC=0,Input_Mode=1,Input_Depth=16,Output_Mode=1,Output_Depth=16) ConvertFromStacked I guess now I'm wondering why SMDegrain outputs seemingly different 16-bit than F3KDB, since the F3KDB output has no issue with the "ConvertFromStacked" call. Anyway, thanks again for your help. |
||
21st May 2019, 10:55 | #528 | Link | |
Registered User
Join Date: Jul 2012
Posts: 1,213
|
Quote:
And there is no mention of NNEDI3 not handling 16 bits |
|
21st May 2019, 12:36 | #529 | Link |
Broadcast Encoder
Join Date: Nov 2013
Location: Royal Borough of Kensington & Chelsea, UK
Posts: 2,904
|
@LouieChuckyMerry... You are feeding NNEDI3_RPow2 with 16bit stacked data while it's expecting 8bit.
Please note that the Jean-Philippe mod of NNEDI3 works in planar only, so it expects 8bit/10bit/12bit/14bit/16bit planar, not stacked nor interleaved, however SMDegrain with lsb=true is working in 16bit stacked. This is what you gotta do: Code:
#Indexing your 8bit source using your preferred indexer FFMpegSource2("video.ts") #Bring everything up to 16bit stacked Dither_Convert_8_To_16() #Denoise with 16bit stacked precision SMDegrain(TR=2,ThSAD=200,ContraSharp=True,RefineMotion=True,Plane=0,PreFilter=2,Chroma=False,LSB=True,LSB_Out=True) #Upscale with 16bit stacked precision nnedi3_resize16(target_width=960, target_height=720, mixed=true, thr=1.0, elast=1.5, nns=4, qual=2, etype=0, pscrn=4, threads=0, tv_range=true, kernel_d="Spline", kernel_u="Spline", taps=6, f_d=1.0, f_u=2.0, sharp=0, lsb_in=true, lsb=true) #Sharpening #please note that you can't use awarpsharp2 as you did #because awarpsharp is expecting 8bit planar #while you are feeding it with 16bit stacked #so you need to use aWarpSharp4xx aWarpSharp4xx(depth=5, lsb=true) #Do not use Sharpen(0.2) #not only you can't use it with 16bit stacked #but it's also a very basic and simple sharpening #which does not work well; #if you really have to use something else #Line Darkening #You did everything correctly this time #as you brought everything back to 8bit #you filtered with FastLineDarkenMod and awarpsharp2 #two filters that work in 8bit planar #then you brought the result back to 16bit stacked #and you applied the differences to the original 16bit stacked F=DitherPost(Mode=-1) S=F.FastLineDarkenMod(Strength=24,Prot=6).aWarpSharp2(Blur=4,Type=1,Depth=8,Chroma=2) D=MT_MakeDiff(S,F).Dither_Convert_8_To_16() Dither_Add16(Last,D,Dif=True,U=2,V=2) #Debanding with 16bit stacked precision #You did everything correctly this time as well #as you specifically told f3kdb that it's getting 16bit stacked #as input and that it should work internally at 16bit #and output 16bit stacked F3KDB(Y=100,Cb=100,Cr=100,GrainY=0,GrainC=0,Input_Mode=1,Input_Depth=16,Output_Mode=1,Output_Depth=16) |
21st May 2019, 14:14 | #530 | Link | ||
Registered User
Join Date: Feb 2014
Posts: 355
|
Quote:
Quote:
FranceBB: Thank you very much for your educational explanations; they're really helpful to an AviSynth hobbyist such as myself . 1) After perusing this entire thread I eventually came to understand that jpsdr's port of NNEDI3 doesn't work with stacked 16-bit. What I wonder is, would this: Code:
### Overall Temporal Denoise ### SMDegrain(TR=2,ThSAD=200,ContraSharp=True,RefineMotion=True,Plane=0,PreFilter=2,Chroma=False,LSB=True,LSB_Out=False) ### Resize ### NNEDI3_RPow2(RFactor=2,CShift="Spline64Resize",FWidth=960,FHeight=1440) aWarpSharp2(Depth=5) Sharpen(0.2) ### Darken-Thin Lines ### Dither_Convert_8_To_16() F=DitherPost(Mode=-1) S=F.FastLineDarkenMod(Strength=24,Prot=6).aWarpSharp2(Blur=4,Type=1,Depth=8,Chroma=2) D=MT_MakeDiff(S,F).Dither_Convert_8_To_16() Dither_Add16(Last,D,Dif=True,U=2,V=2) 2) I encountered your NNEDI3_Resize16 line in this thread and was able to make it work after some effort. Thank you. I reckon it's better to upscale in 16-bits, no? 3) I did some searching, with two different engines, for aWarpSharp4 and found, literally, nothing. Do you know where I might find a copy? 4) Please, any suggestions to replace Sharpen(0.2)? 5) Thanks for your kind help . |
||
21st May 2019, 15:29 | #531 | Link | |
Broadcast Encoder
Join Date: Nov 2013
Location: Royal Borough of Kensington & Chelsea, UK
Posts: 2,904
|
1) Yes, that would be the correct way as you are feeding it with 8bit planar data.
2) Yep, definitely better to have more precision whenever you can (at the expense of speed). 3) Sure, there you go: https://forum.doom9.org/showthread.p...87#post1715287 4) If you are working in 8bit planar: LSFMod. If you are working in 16bit interleaved, either MCLS_16 or BicubicSharp. For 16bit stacked, I'm using RKS but it's closed source and I can't share it as it has been developed years ago by the engineer who taught me encoding. Quote:
Honestly, if planar was introduced years ago in "vanilla" Avisynth, we wouldn't have had this "mess" of filters supporting stacked, some others supporting interleaved, some others supporting both (like f3kdb) but not planar > 8bit, some others supporting planar only 8bit, some others supporting planar high bit depth (8bit/10bit/12bit/14bit/16bit/32bit) but not stacked nor interleaved ecc. |
|
22nd May 2019, 01:45 | #532 | Link | |||||
Registered User
Join Date: Feb 2014
Posts: 355
|
Quote:
Quote:
Quote:
Quote:
Quote:
|
|||||
22nd May 2019, 04:42 | #533 | Link | |
Broadcast Encoder
Join Date: Nov 2013
Location: Royal Borough of Kensington & Chelsea, UK
Posts: 2,904
|
Quote:
|
|
22nd May 2019, 05:13 | #534 | Link |
Useful n00b
Join Date: Jul 2014
Posts: 1,667
|
If you are using Avisynth+ and DGDecNV, then you have DGSharpen(), which is a very fast CUDA implementation with functionality like LSFmod. It works in 8 or 16-bit depth.
You really should get away from all the high-bit-depth hacks, IMHO, and go for native support. |
22nd May 2019, 14:42 | #535 | Link | ||
Registered User
Join Date: Feb 2014
Posts: 355
|
Quote:
Quote:
|
||
22nd May 2019, 15:14 | #536 | Link | |
Useful n00b
Join Date: Jul 2014
Posts: 1,667
|
Quote:
|
|
22nd May 2019, 17:26 | #537 | Link |
Registered User
Join Date: Jan 2012
Location: Mesopotamia
Posts: 2,587
|
like videoh said, go for native HBD
SMDegrain already work with native HBD in many settings included the Default setting for now, other settings waiting for updates for dll's to support HBD, LSFmod work with HBD too and aside form that, aWarpSharp4 link is not last update, the last one in my signature
__________________
See My Avisynth Stuff Last edited by real.finder; 22nd May 2019 at 17:45. |
23rd May 2019, 02:35 | #538 | Link | ||
Registered User
Join Date: Feb 2014
Posts: 355
|
Quote:
Quote:
Code:
SMDegrain(TR=3,ThSAD=XXX,RefineMotion=True,Plane=0,Chroma=False,LSB=True,LSB_Out=True) Last edited by LouieChuckyMerry; 23rd May 2019 at 02:37. Reason: Specificity |
||
23rd May 2019, 14:29 | #540 | Link | |
Registered User
Join Date: Jan 2012
Location: Mesopotamia
Posts: 2,587
|
all about SMDegrain HBD
Quote:
there are many ways, the standard way is just use the SMDegrain with any avs+ HBD Code:
ConvertBits(16) #if your source not HBD already SMDegrain(tr=4,thSAD=600,contrasharp=false,refinemotion=false,truemotion=true,plane=4) ConvertBits(8,dither=1) #if you want to get back to 8bit so back then pinterf came with another method with SMDegrain it will be like this Code:
#8bit source c=last SMDegrain(globals=3,tr=4,PreFilter=4) global fv1 = fv1.MScalevect(bits=16) global fv2 = fv2.MScalevect(bits=16) global fv3 = fv3.MScalevect(bits=16) global fv4 = fv4.MScalevect(bits=16) global bv1 = bv1.MScalevect(bits=16) global bv2 = bv2.MScalevect(bits=16) global bv3 = bv3.MScalevect(bits=16) global bv4 = bv4.MScalevect(bits=16) c ConvertBits(16) SMDegrain(globals=1,tr=4,thSAD=600,contrasharp=false,refinemotion=false,truemotion=true,plane=4) ConvertBits(8,dither=1) then for more speed pinterf allow MDegrainX passing 8/16/32bit clip and super with 8bit vectors https://forum.doom9.org/showthread.p...39#post1834939 simply just use SMDegrain with HBD but with 8bit prefilter, but it's still not fast enough https://forum.doom9.org/showthread.p...18#post1835018 so the last one is using n16=True,n16_Out=True instead of lsb and you will get native 16 HBD clip from your 8bit source with more speed than lsb without hacks but keep in mind that even if n16 is lsb alternative, it not 100% same
__________________
See My Avisynth Stuff Last edited by real.finder; 21st July 2019 at 07:41. |
|
|
|