This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

How is called this kind of "defect" and how to mitigate? (if possible)
#9
Okay, no wonder that isn't working!
Your script is:
# Imports import vapoursynth as vs # getting Vapoursynth core import sys import os core = vs.core # Import scripts folder scriptPath = 'C:/Program Files/Hybrid/64bit/vsscripts' sys.path.insert(0, os.path.abspath(scriptPath)) # loading plugins core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/SourceFilter/LSmashSource/LSMASHSource.dll") # defining beforeEnd-function - START def beforeEnd(clip): # converting interlaced to half-height progressive for filtering (vsMCTemporalDenoise) (separate fields) clip = core.resize.Bicubic(clip=clip, format=vs.YUV444P8, range_s="limited") clip = core.std.SeparateFields(clip, tff=False) clipEven = clip[::2] # resolution 720x288 clipEven = core.std.SetFrameProps(clip=clipEven, _FieldBased=vs.FIELD_PROGRESSIVE) # progressive clipOdd = clip[1::2] # resolution 720x288 clipOdd = core.std.SetFrameProps(clip=clipOdd, _FieldBased=vs.FIELD_PROGRESSIVE) # progressive # denoising using MCTemporalDenoise clipEven = denoise.MCTemporalDenoise(i=clipEven, settings="very high", ncpu=10) # denoising using MCTemporalDenoise clipOdd = denoise.MCTemporalDenoise(i=clipOdd, settings="very high", ncpu=10) # converting half-height progressive to interlacedbefore deinterlacing clip = core.std.Interleave([clipOdd, clipEven]) clip = core.std.DoubleWeave(clip=clip, tff=False) # resolution 720x576 clip = core.std.SelectEvery(clip, 2, 0) clip = core.std.SetFrameProps(clip=clip, _FieldBased=vs.FIELD_TOP) # tff # Deinterlacing using TIVTC clip = core.tivtc.TFM(clip=clip, chroma=True) clip = core.tivtc.TDecimate(clip=clip, mode=7, rate=23.9760, dupThresh=0.04, vidThresh=3.50, sceneThresh=15.00)# new fps: 23.976 # Making sure content is preceived as frame based clip = core.std.SetFrameProps(clip=clip, _FieldBased=vs.FIELD_PROGRESSIVE) # progressive # applying anti aliasing using santiag clip = antiAliasing.santiag(c=clip, strh=3, strv=3, nns=2, qual=2, pscrn=2, opencl=True) return clip # defining beforeEnd-function - END # Import scripts import validate # Source: 'C:\Users\Bfield\Desktop\defect.avi' # Current color space: YUV420P8, bit depth: 8, resolution: 720x576, frame rate: 30fps, scanorder: progressive, yuv luminance scale: limited, matrix: 470bg, format: ULH0 # Loading C:\Users\Bfield\Desktop\defect.avi using LWLibavSource clip = core.lsmas.LWLibavSource(source="C:/Users/Bfield/Desktop/defect.avi", format="YUV420P8", stream_index=0, cache=0, prefer_hw=0) frame = clip.get_frame(0) # setting color matrix to 470bg. clip = core.std.SetFrameProps(clip, _Matrix=vs.MATRIX_BT470_BG) # setting color transfer (vs.TRANSFER_BT601), if it is not set. if validate.transferIsInvalid(clip): clip = core.std.SetFrameProps(clip=clip, _Transfer=vs.TRANSFER_BT601) # setting color primaries info (to vs.PRIMARIES_BT470_BG), if it is not set. if validate.primariesIsInvalid(clip): clip = core.std.SetFrameProps(clip=clip, _Primaries=vs.PRIMARIES_BT470_BG) # setting color range to TV (limited) range. clip = core.std.SetFrameProps(clip=clip, _ColorRange=vs.RANGE_LIMITED) # making sure frame rate is set to 30fps clip = core.std.AssumeFPS(clip=clip, fpsnum=30, fpsden=1) # making sure the detected scan type is set (detected: progressive) clip = core.std.SetFrameProps(clip=clip, _FieldBased=vs.FIELD_PROGRESSIVE) # progressive clip = beforeEnd(clip) # set output frame rate to 30fps (progressive) clip = core.std.AssumeFPS(clip=clip, fpsnum=30, fpsden=1) # output clip.set_output()
In your custom section you use:
'denoise','tivtc','antiAliasing' but you don't import the used scripts, or load the required plugins.

No clue why you are using a custom section, to begin with.
The stuff I did in post #3, you can archive by:
  • loading your source
  • enabling and settings 'Filtering->(De-)Interlace/Telecine->Overwrite input scan type to' to 'telecine'
  • setting 'Filtering->(De-)Interlace/Telecine->TIVTC Settings->TDecimate->Mode' to '7'
  • setting 'Filtering->(De-)Interlace/Telecine->TIVTC Settings->TDecimate->Rate' to '23.976'
  • setting 'Filtering->Vapoursynth->Misc->Script->Filter interlace handling' to 'separate fields'
  • enabling 'Filtering->Vapoursynth->DeNoise->MC Temporal Denoise'
  • setting 'Filtering->Vapoursynth->DeNoise->MC Temporal Denoise->Settings' to 'very high' (optionall increasing ncpu to 10)
  • switching to 'Filtering->Vapoursynth->Misc->Filter Order/Queue' and moving 'MCTemporalDenois' above 'Deinterlace'
  • enabling 'Filtering->Vapoursynth->Line->AntiAliasing->Santiag'
  • setting 'Filtering->Vapoursynth->Line->AntiAliasing->Santiag->strength->h&v' both to '3 (optionally enabling 'OpenCL')
For me, the Vapoursynth Script Preview then shows:
# Imports import vapoursynth as vs # getting Vapoursynth core import ctypes import sys import os core = vs.core # Import scripts folder scriptPath = 'F:/Hybrid/64bit/vsscripts' sys.path.insert(0, os.path.abspath(scriptPath)) # Loading Support Files Dllref = ctypes.windll.LoadLibrary("F:/Hybrid/64bit/vsfilters/Support/libfftw3f-3.dll") # loading plugins core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/Support/libsangnom.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/Support/fmtconv.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/Support/EEDI2.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/Support/EEDI3m_opencl.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/ResizeFilter/nnedi3/NNEDI3CL.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/DeinterlaceFilter/TIVTC/libtivtc.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/MiscFilter/MiscFilters/MiscFilters.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/DenoiseFilter/TTempSmooth/TTempSmooth.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/DenoiseFilter/DFTTest/DFTTest.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/DenoiseFilter/NEO_FFT3DFilter/neo-fft3d.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/Support/DCTFilter.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/DeblockFilter/Deblock/Deblock.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/Support/libmvtools.dll") core.std.LoadPlugin(path="F:/Hybrid/64bit/vsfilters/SourceFilter/LSmashSource/LSMASHSource.dll") # Import scripts import antiAliasing import denoise import validate # Source: 'C:\Users\Selur\Desktop\defect.avi' # Current color space: YUV420P8, bit depth: 8, resolution: 720x576, frame rate: 30fps, scanorder: telecine, yuv luminance scale: limited, matrix: 470bg, format: ULH0 # Loading C:\Users\Selur\Desktop\defect.avi using LWLibavSource clip = core.lsmas.LWLibavSource(source="C:/Users/Selur/Desktop/defect.avi", format="YUV420P8", stream_index=0, cache=0, prefer_hw=0) frame = clip.get_frame(0) # setting color matrix to 470bg. clip = core.std.SetFrameProps(clip, _Matrix=vs.MATRIX_BT470_BG) # setting color transfer (vs.TRANSFER_BT601), if it is not set. if validate.transferIsInvalid(clip): clip = core.std.SetFrameProps(clip=clip, _Transfer=vs.TRANSFER_BT601) # setting color primaries info (to vs.PRIMARIES_BT470_BG), if it is not set. if validate.primariesIsInvalid(clip): clip = core.std.SetFrameProps(clip=clip, _Primaries=vs.PRIMARIES_BT470_BG) # setting color range to TV (limited) range. clip = core.std.SetFrameProps(clip=clip, _ColorRange=vs.RANGE_LIMITED) # making sure frame rate is set to 30fps clip = core.std.AssumeFPS(clip=clip, fpsnum=30, fpsden=1) # making sure the detected scan type is set (detected: telecine) clip = core.std.SetFrameProps(clip=clip, _FieldBased=vs.FIELD_TOP) # tff # converting interlaced to half-height progressive for filtering (vsMCTemporalDenoise) (separate fields) clip = core.resize.Bicubic(clip=clip, format=vs.YUV444P8, range_s="limited") clip = core.std.SeparateFields(clip, tff=False) clipEven = clip[::2] # resolution 720x288 clipEven = core.std.SetFrameProps(clip=clipEven, _FieldBased=vs.FIELD_PROGRESSIVE) # progressive clipOdd = clip[1::2] # resolution 720x288 clipOdd = core.std.SetFrameProps(clip=clipOdd, _FieldBased=vs.FIELD_PROGRESSIVE) # progressive # denoising using MCTemporalDenoise clipEven = denoise.MCTemporalDenoise(i=clipEven, settings="very high", ncpu=10) # denoising using MCTemporalDenoise clipOdd = denoise.MCTemporalDenoise(i=clipOdd, settings="very high", ncpu=10) # converting half-height progressive to interlacedbefore deinterlacing clip = core.std.Interleave([clipOdd, clipEven]) clip = core.std.DoubleWeave(clip=clip, tff=False) # resolution 720x576 clip = core.std.SelectEvery(clip, 2, 0) clip = core.std.SetFrameProps(clip=clip, _FieldBased=vs.FIELD_TOP) # tff # Deinterlacing using TIVTC clip = core.tivtc.TFM(clip=clip) clip = core.tivtc.TDecimate(clip=clip, mode=7, rate=23.9760, dupThresh=0.04, vidThresh=3.50, sceneThresh=15.00)# new fps: 23.976 # Making sure content is preceived as frame based clip = core.std.SetFrameProps(clip=clip, _FieldBased=vs.FIELD_PROGRESSIVE) # progressive # applying anti aliasing using santiag clip = antiAliasing.santiag(c=clip, strh=3, strv=3, nns=2, qual=2, pscrn=2, opencl=True) # adjusting output color from: YUV444P8 to YUV420P10 for NVEncModel clip = core.resize.Bicubic(clip=clip, format=vs.YUV420P10, range_s="limited") # set output frame rate to 23.976fps (progressive) clip = core.std.AssumeFPS(clip=clip, fpsnum=24000, fpsden=1001) # output clip.set_output()

In theory, you could use a custom section, but when using a custom section you are responsible to load all dependencies&co.

Cu Selur
----
Dev versions are in the 'experimental'-folder of my GoogleDrive, which is linked on the download page.
Reply


Messages In This Thread
RE: How is called this kind of "defect" and how to mitigate? (if possible) - by Selur - 25.03.2025, 12:33

Forum Jump:


Users browsing this thread: 1 Guest(s)