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.

[HELP] Upscaling VCD .dat files problem
#1
I added two .DAT files to Hybrid, both sides of a VCD (MPEG-1). 

Hybrid correctly reported these as 25fps progressive. However, when denoising and upscaling to 720, the footage is being slowed down resulting in twice the running time, but to confuse matters the running time of the exported files still shows as 25fps. Any suggestions what could be happening?
Reply
#2
Without a debug output: No.
Additionally, when handling vcds best repack the content with https://www.videohelp.com/software/vcdgear (Windows only).

Cu Selur
----
Dev versions are in the 'experimental'-folder of my GoogleDrive, which is linked on the download page.
Offline between (including) 29th of June and 5th of July => RochHarz Festival
Reply
#3
Thanks for the above link, I've now converted the .dat files to mpg.

I've tried numerous DeBlock settings within the DeBlock_QED filter, but I'm still seeing lots of blocking/compression artifacts when upscaling to 720p. 

Any suggestions? I need to go up to 1080p on this for a Blu-ray project.

I'd forgotten just how poor VCDs look.

sample VCD clip
Reply
#4
Normal deblocking filters will only help with the first iteration of encoding, if you reencode blocking content again the will not really help unless you crank the strength up. (machine learning based deblocking like might help better)
Have you tried something like MCTemporalDenoise with a high preset, SpotLess iwth tr=3 and or SMDeGrain?
i.e.:
# Spot removal using SpotLess clip = SpotLess.SpotLess(clip=clip, radT=3, rec=True, pel=1, smoother="zsmooth") # applying deblocking using DeBlock QED clip = deblock.Deblock_QED(clip, quant1=60, quant2=60, aOff2=4, bOff2=4) # removing grain using SMDegrain clip = smdegrain.SMDegrain(input=clip, tr=3, thSAD=600, thSADC=256, interlaced=False, opencl=True, device=-1)
[Image: grafik.png]
to get things starting?
The problem with such content is to rescue some sharpness. Wink

Cu Selur

Ps.: there seems to have been a mix up with pc vs tv luma scaling in the past of this clip, so using something like
clip = core.std.Levels(clip=clip, min_in=36, max_in=212, min_out=16, max_out=235)
might also be a good idea.

Ps.: conventional filtered: script, clip stabilizing is a pain with that intro,...
----
Dev versions are in the 'experimental'-folder of my GoogleDrive, which is linked on the download page.
Offline between (including) 29th of June and 5th of July => RochHarz Festival
Reply
#5
Do you think it's best to deblock and denoise and then upscale the output files?
Reply
#6
Doesn't really matter if you use a lossless temporal file as intermediate or not.
Adding QTGMC(Filter) with InputType=3 does help with the flickering of the text in the intro a lot.
----
Dev versions are in the 'experimental'-folder of my GoogleDrive, which is linked on the download page.
Offline between (including) 29th of June and 5th of July => RochHarz Festival
Reply
#7
# Spot removal using SpotLess clip = SpotLess.SpotLess(clip=clip, radT=3, rec=True, pel=1, smoother="zsmooth") # applying deblocking using DeBlock QED clip = deblock.Deblock_QED(clip, quant1=60, quant2=60, aOff2=4, bOff2=4) # removing grain using SMDegrain clip = smdegrain.SMDegrain(input=clip, tr=3, thSAD=600, thSADC=256, interlaced=False, opencl=True, device=-1)


I can't seem to match these settings - what are the actual settings in the filters?
Reply
#8
you can skip ', smoother="zsmooth"' and ', opencl=True, device=-1' in case that helps,... not at home atm.
----
Dev versions are in the 'experimental'-folder of my GoogleDrive, which is linked on the download page.
Offline between (including) 29th of June and 5th of July => RochHarz Festival
Reply
#9
I seem to be encountering some ExitCode crash problems with Vs filtering - debug attached. I'm also not able to get a preview window. Can I do the same with Avisynth?

edit: same crashing with Avisynth filtering.

Quote:2025.08.18 - 13:14:58_Windows 10 Version 22H2 (64bit)_2025.08.14.1 - level 9: FFmpeg output: [yuv4mpegpipe @ 000001529b090480] Header too large.
[in#0 @ 000001529b0900c0] Error opening input: Invalid argument
Error opening input file -.
Error opening input files: Invalid argument
Reply
#10
# Imports import vapoursynth as vs # getting Vapoursynth core import ctypes 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 Support Files Dllref = ctypes.windll.LoadLibrary("C:/Program Files/Hybrid/64bit/vsfilters/Support/libfftw3f-3.dll") # loading plugins core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/GrainFilter/RemoveGrain/RemoveGrainVS.dll") core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/DenoiseFilter/CTMF/CTMF.dll") core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/Support/DCTFilter.dll") core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/DeblockFilter/Deblock/Deblock.dll") core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/Support/fmtconv.dll") core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/MiscFilter/MiscFilters/MiscFilters.dll") core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/DenoiseFilter/TTempSmooth/TTempSmooth.dll") core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/Support/libmvtools.dll") core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/SourceFilter/d2vSource/DGDecode.dll") # Import scripts import nnedi3_resample import smdegrain import deblock import SpotLess import validate # Source: 'S:\Hybrid-IN\B.mpg' # Current color space: YUV420P8, bit depth: 8, resolution: 352x288, frame rate: 25fps, scanorder: progressive, yuv luminance scale: limited, matrix: 470bg, format: mpeg-1 # Loading S:\Hybrid-IN\B.mpg using DGDecode clip = core.dgdecode.MPEG2Source("M:/5994-2997 Prog-Temp/mpg_0fed4a8b659097cc82e8589d2b702de0_853323747.d2v",info=3)# 25 fps, scanorder: progressive 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 25fps clip = core.std.AssumeFPS(clip=clip, fpsnum=25, fpsden=1) # making sure the detected scan type is set (detected: progressive) clip = core.std.SetFrameProps(clip=clip, _FieldBased=vs.FIELD_PROGRESSIVE) # progressive # adjusting color space from YUV420P8 to RGB24 for vsLevels clip = core.resize.Bicubic(clip=clip, format=vs.RGB24, matrix_in_s="470bg", range_s="limited") # adjusting color using Levels on RGB24 (8 bit) clip = core.std.Levels(clip=clip, min_in=36, max_in=212, min_out=16, max_out=235) # adjusting color space from RGB24 to YUV444P16 for vsSpotLess clip = core.resize.Bicubic(clip=clip, format=vs.YUV444P16, matrix_s="470bg", range_s="limited") # Spot removal using SpotLess clip = SpotLess.SpotLess(clip=clip, radT=3, asearch=4, rec=True, pel=1, smoother="ttsmooth") # applying deblocking using DeBlock QED clip = deblock.Deblock_QED(clip, quant1=60, quant2=60, aOff2=4, bOff2=4, uv=1) # removing grain using SMDegrain clip = smdegrain.SMDegrain(input=clip, tr=3, thSAD=600, thSADC=256, interlaced=False) # Resizing using 10 - bicubic spline clip = core.fmtc.resample(clip=clip, kernel="spline16", w=960, h=720, interlaced=False, interlacedd=False) # resolution 960x720 before YUV444P16 after YUV444P16 # adjusting output color from: YUV444P16 to YUV422P10 for ProResModel clip = core.resize.Bicubic(clip=clip, format=vs.YUV422P10, range_s="limited", dither_type="error_diffusion") # set output frame rate to 25fps (progressive) clip = core.std.AssumeFPS(clip=clip, fpsnum=25, fpsden=1) # output clip.set_output()
script looks fine to me, but crashes.
=> Check the Vapourynth Preview. If the preview still does not work, you need to check your setup and the used filters.
[code[Dllref = ctypes.windll.LoadLibrary("C:/Program Files/Hybrid/64bit/vsfilters/Support/libfftw3f-3.dll")
# loading plugins
core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/GrainFilter/RemoveGrain/RemoveGrainVS.dll")
core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/DenoiseFilter/CTMF/CTMF.dll")
core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/Support/DCTFilter.dll")
core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/DeblockFilter/Deblock/Deblock.dll")
core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/Support/fmtconv.dll")
core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/MiscFilter/MiscFilters/MiscFilters.dll")
core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/DenoiseFilter/TTempSmooth/TTempSmooth.dll")
core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/Support/libmvtools.dll")
core.std.LoadPlugin(path="C:/Program Files/Hybrid/64bit/vsfilters/SourceFilter/d2vSource/DGDecode.dll")[/code]
Check the loaded dlls with https://www.dependencywalker.com/ to see if your system is missing some dependency.

Assuming the filters are all present in Avisynth you could use that.

Cu Selur
----
Dev versions are in the 'experimental'-folder of my GoogleDrive, which is linked on the download page.
Offline between (including) 29th of June and 5th of July => RochHarz Festival
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)