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. |
![]() |
#3762 | Link |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,497
|
Yes, always.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
![]() |
![]() |
![]() |
#3763 | Link |
Pig on the wing
Join Date: Mar 2002
Location: Finland
Posts: 5,545
|
If I have a VFR video clip, say like part A deinterlaced to 25fps and part B bobbed to 50fps in the script and the two parts combined with A+B - what is the proper way to get the correct timecodes out with vspipe? Should I use AssumeFPS to set the framerate to 25fps (which I will use when I feed it to x265) or leave it as it is?
__________________
And if the band you're in starts playing different tunes I'll see you on the dark side of the Moon... |
![]() |
![]() |
![]() |
#3764 | Link |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,497
|
R49 released!
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
![]() |
![]() |
![]() |
#3765 | Link | |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,497
|
Quote:
Or that's how I think it should work.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
|
![]() |
![]() |
![]() |
#3766 | Link | |
Pig on the wing
Join Date: Mar 2002
Location: Finland
Posts: 5,545
|
Quote:
![]() The timecodes have two steps, 20ms and 40ms in the 50fps parts. The 25fps parts have 40ms and 80ms steps. Code:
# timecode format v2 0.000000 20.000000 60.000000 80.000000 120.000000 . . . 46600.000000 46680.000000 46720.000000 46800.000000 46840.000000 46920.000000 46960.000000 Code:
# timestamp format v2 0 20 40 60 . . . 408000 408040 408080 408120 408160
__________________
And if the band you're in starts playing different tunes I'll see you on the dark side of the Moon... |
|
![]() |
![]() |
![]() |
#3767 | Link | |||
Registered User
Join Date: Sep 2010
Location: Ukraine, Bohuslav
Posts: 376
|
Boulder
You probably doing it wrong. Yesterday I had hybrid video file encoded as MBAFF (no actual combed frames, but it's 30000/1001i), and some sections are upscaled from 24000/1001p. So I need to decimate only certain sections and produce VFR video. I'll describe my solution bellow and how to actually get valid timecodes (Myrs answer seems not so clear for you). The whole process is described to understand my workflow and most likely irrelevant for you, but you can adapt that to your case and use only what you need from it. First, I have to check with VDecimate(dryrun=True) if scene actually telecined. The result for my video was Quote:
Code:
vfr_pool = list() for pos, start in enumerate(scenes, 1): # start from 1 for simplicity of the algo if pos >= len(scenes): # last frame in list is the end of last section, so I want to terminate loop on it break end = scenes[pos] if pos&1: # decimate only 1, 3, 5, 7, etc. sections vfr_pool.append(core.vivtc.VDecimate(source[start:end])) else: vfr_pool.append(source[start:end]) Quote:
Quote:
I really want tdecimate's mode 4/5 solution in vapoursynth, but it seems like no one want to port that. |
|||
![]() |
![]() |
![]() |
#3768 | Link |
Pig on the wing
Join Date: Mar 2002
Location: Finland
Posts: 5,545
|
Thank you, I will take a look at your method
![]() I used this kind of approach for creating the test clip, the first and third parts are bobbed. Code:
clp = core.dgdecodenv.DGSource(r"F:\Temp\Captures\monty\monty_s01e01.dgi", cl=244, cr=244) result = haf.QTGMC(core.std.Trim(clp, 0,719), Preset='very fast', Search=5, SearchParam=8, PelSearch=8, ChromaMotion=True, ChromaNoise=False, SourceMatch=2, Lossless=2, EZKeepGrain=0.4, Sharpness=0.1, TR2=0, TFF=True) result = result + haf.QTGMC(core.std.Trim(clp, 720,2890), Preset='very fast', Search=5, SearchParam=8, PelSearch=8, ChromaMotion=True, ChromaNoise=False, SourceMatch=2, Lossless=2, EZKeepGrain=0.4, Sharpness=0.1, TR2=0, TFF=True, InputType=2) result = result + haf.QTGMC(core.std.Trim(clp, 2891,3935), Preset='very fast', Search=5, SearchParam=8, PelSearch=8, ChromaMotion=True, ChromaNoise=False, SourceMatch=2, Lossless=2, EZKeepGrain=0.4, Sharpness=0.1, TR2=0, TFF=True) result = result + haf.QTGMC(core.std.Trim(clp, 3936,4428), Preset='very fast', Search=5, SearchParam=8, PelSearch=8, ChromaMotion=True, ChromaNoise=False, SourceMatch=2, Lossless=2, EZKeepGrain=0.4, Sharpness=0.1, TR2=0, TFF=True, InputType=2) result.set_output() Code:
#0, 719 i #720, 2890 p #2891, 3935 i #3936, 4428 p #4429, 6676 i #6677, 6834 p #6835, 10567 i #10568, 12260 p #12261, 23093 i #23094, 23991 p #23992, 24154 i #24155, 25876 p #25877, 26664 i #26665, 30805 p #30806, 31140 i #31141, 40655 p #40656, 43509 i #43510, 43599 p #43600, 44268 i #44269, 44403 p #44404, 44831 i #44832, 45795 p #45796, 47686 i
__________________
And if the band you're in starts playing different tunes I'll see you on the dark side of the Moon... |
![]() |
![]() |
![]() |
#3769 | Link | ||
Registered User
Join Date: Sep 2010
Location: Ukraine, Bohuslav
Posts: 376
|
Apparently timecodes produced with vspipe are weird. Working solution is
Quote:
Quote:
|
||
![]() |
![]() |
![]() |
#3771 | Link |
I'm Siri
Join Date: Oct 2012
Location: void
Posts: 2,633
|
I updated to r49 and weird things happened.
I ran the same std.Convolution script for speed test and the script ran for 497.17fps, but it was 2400+fps before the update! my custom GaussBlur filter also ran a lot slower, from 1800+fps before update to now 483.92fps (gcc -O3) Last edited by feisty2; 29th March 2020 at 14:04. |
![]() |
![]() |
![]() |
#3772 | Link |
Registered User
Join Date: Jun 2012
Location: Ibiza, Spain
Posts: 321
|
std.Convolution with same parameters as you runs at 2384 fps here (Linux), maybe Windows build is compiled without optimizations?
I also did try to run it with core.std.SetMaxCPU('none') but it made no difference? Maybe I'm too sleepy and I'm doing something wrong. Code:
import vapoursynth as vs core = vs.get_core() core.std.SetMaxCPU('none') clip = core.std.BlankClip(format=vs.GRAYS, length=100000, fpsnum=24000, fpsden=1001, keep=True) clip = core.std.Convolution(clip, matrix=[1,2,1,2,4,2,1,2,1]) clip.set_output() |
![]() |
![]() |
![]() |
#3773 | Link | |
I'm Siri
Join Date: Oct 2012
Location: void
Posts: 2,633
|
Quote:
![]() |
|
![]() |
![]() |
![]() |
#3775 | Link | |
Registered User
Join Date: Dec 2005
Location: Germany
Posts: 1,744
|
Quote:
vspipe.exe .\bla.vpy . Output 100000 frames in 6.20 seconds (16138.35 fps) # without core.std.SetMaxCPU('none') Output 100000 frames in 12.73 seconds (7856.92 fps) #with core.std.SetMaxCPU('none')
__________________
AVSRepoGUI // VSRepoGUI - Package Manager for AviSynth // VapourSynth VapourSynth Portable FATPACK || VapourSynth Database || https://github.com/avisynth-repository |
|
![]() |
![]() |
![]() |
#3776 | Link |
Pajas Mentales...
Join Date: Dec 2004
Location: Spanishtán
Posts: 496
|
with/without dual xeon (:/) (linux, -02)
Code:
└───╼ vspipe test.vpy /dev/null Output 100000 frames in 15.89 seconds (6293.29 fps) └───╼ vspipe test.vpy /dev/null Output 100000 frames in 9.40 seconds (10642.37 fps) lanuched the same in yakuake (based on konsole, not use as bakend) Code:
┌─┤[$]|[sl1pkn07]|[sL1pKn07]|[~/aplicaciones/vapoursynth-git]| └───╼ cat test.vpy import vapoursynth as vs core = vs.get_core() core.std.SetMaxCPU('none') clip = core.std.BlankClip(format=vs.GRAYS, length=100000, fpsnum=24000, fpsden=1001, keep=True) clip = core.std.Convolution(clip, matrix=[1,2,1,2,4,2,1,2,1]) clip.set_output() ┌─┤[$]|[sl1pkn07]|[sL1pKn07]|[~/aplicaciones/vapoursynth-git]| └───╼ vspipe test.vpy /dev/null Output 100000 frames in 8.39 seconds (11923.86 fps) ┌─┤[$]|[sl1pkn07]|[sL1pKn07]|[~/aplicaciones/vapoursynth-git]| └───╼ cat test.vpy import vapoursynth as vs core = vs.get_core() #core.std.SetMaxCPU('none') clip = core.std.BlankClip(format=vs.GRAYS, length=100000, fpsnum=24000, fpsden=1001, keep=True) clip = core.std.Convolution(clip, matrix=[1,2,1,2,4,2,1,2,1]) clip.set_output() ┌─┤[$]|[sl1pkn07]|[sL1pKn07]|[~/aplicaciones/vapoursynth-git]| └───╼ vspipe test.vpy /dev/null Output 100000 frames in 7.32 seconds (13656.67 fps) ┌─┤[$]|[sl1pkn07]|[sL1pKn07]|[~/aplicaciones/vapoursynth-git]| └───╼ htop with vspipe in yakuake shot Last edited by sl1pkn07; 29th March 2020 at 18:49. |
![]() |
![]() |
![]() |
#3778 | Link |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,497
|
Because your runtimes are old and you didn't unchecked the option.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
![]() |
![]() |
![]() |
#3779 | Link |
Registered User
Join Date: Nov 2013
Posts: 136
|
You mean it checks for the installed runtimes? Because I'd already installed both x86 and x64 versions of it. You're right there's an option for it which I somehow missed.
Thank you. BTW, I installed Python 3.8 in Program Files and moved its path to the end of PATH variable so that I'd be able to use the already installed 3.7.4 version, things appear to work so far, but I thought I'd ask here whether that's OK or not. P.S. I updated from R45 so I thought I'd see some speed improvements considering AVX2 has been added since that version, but I got almost the same speeds, so was wondering if there's a way to check whether I was doing something wrong and that AVX2 was actually being used. Last edited by leon; 7th April 2020 at 21:35. |
![]() |
![]() |
![]() |
#3780 | Link | |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,497
|
Quote:
Don't do that python mess. You've most likely ended up using the R48 python module and things just work by accident.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
|
![]() |
![]() |
![]() |
Tags |
speed, vaporware, vapoursynth |
Thread Tools | Search this Thread |
Display Modes | |
|
|