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. |
25th September 2012, 11:35 | #201 | Link |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
That's not much to go on. It crashes with different input formats? Does your cpu have sse2?
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
25th September 2012, 11:51 | #202 | Link |
Registered User
Join Date: Jun 2012
Location: Ibiza, Spain
Posts: 321
|
Yeah, sorry for my poor report, after further testing:
Input is yv12 coming from native ffms2 (BD m2ts) As long as the total sum of pixels is less than 2000000, it does not seem to crash (only played a little resizing before Transpose) Tested on my amd cpu and an i3 friends's one, both with sse2 |
25th September 2012, 15:21 | #203 | Link | |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
Quote:
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
|
25th September 2012, 17:41 | #204 | Link | |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
Quote:
I'll think about what to do with it in the next version. Maybe some kind of automatic argument renaming would be a good idea...
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
|
25th September 2012, 19:49 | #205 | Link |
Registered User
Join Date: Jul 2010
Posts: 448
|
Finally had time to try some scripting, ultimate aim to get (Q)TGMC working. Hit some problems:
- No Bob, Merge or TemporalSmooth -- I cannot replace Bob with the SeparateFields/Resize equivalent because the resizers don't support float sample offsets as they do in Avisynth -- Merge can be replaced with masktools calls, but will be slower -- TemporalSmooth can be kinda replaced with trim and masktools work, but will be much slower and really needs scene change awareness. Any suggestions for an existing external plugin that does the same (MVTools can do it with null vectors, but that seems overkill), or does it need a new plugin to be written? - I have a problem with Interleave (unless I'm being stupid). This script should do nothing, but actually returns a clip with (almost?) every other frame dropped: Code:
#... e = core.std.SelectEvery(clip=c,cycle=2,offsets=[0]) # SelectEven o = core.std.SelectEvery(clip=c,cycle=2,offsets=[1]) # SelectOdd c = core.std.Interleave(clips=[e,o]) #... |
25th September 2012, 21:16 | #207 | Link | |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
Quote:
Code:
e = core.std.SelectEvery(c,2,[0]) <- that's all there is to it, simple You're right. No bob. Maybe you can use some other bob filter and tweak the settings to make it really stupid. I plan to start work on a kind of masktools replacement based on asmjit after R9 is released, it should be a good base for making the merge functionality you want. Temporalsmooth is also just another temporal smoother. I don't think it belongs as a base filter. Maybe someone will come along and rip out some of avisynth's more popular filters and make them standalone plugins. I think it's the best interim solution. I found the interleave bug. A complete brainfart at its best when it was written.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet Last edited by Myrsloik; 25th September 2012 at 21:41. |
|
25th September 2012, 23:40 | #209 | Link |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
You most likely have an old version lying around without realizing it. Delete all copies of vapoursynth.pyd and vscore.dll and reinstall.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
26th September 2012, 02:55 | #211 | Link |
interlace this!
Join Date: Jun 2003
Location: i'm in ur transfers, addin noise
Posts: 4,555
|
here's a replacement for bob, at least using avisynth code (i haven't had time to teach myself python yet):
interleave(separatefields().selecteven().bicubicresize(last.width,last.height,1/3.,1/3.,0,.25,last.width,last.height/2),separatefields().selectodd().bicubicresize(last.width,last.height,1/3.,1/3.,0,-.25,last.width,last.height/2)) i think vapoursynth should have enough internal filters to implement the above line, if the resizers are up to it.
__________________
sucking the life out of your videos since 2004 |
26th September 2012, 03:17 | #212 | Link | |
Registered User
Join Date: Oct 2007
Posts: 135
|
Quote:
|
|
26th September 2012, 11:12 | #213 | Link |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
I've released R9. See http://www.vapoursynth.com/2012/09/r9-the-mostly-done-release/ for the full post with changes and what's on my todo list.
Here's a small example of the new slicing possible with clips in Python: Code:
clip[1:] # equivalent to Trim(c, first=1) clip[:9] # equivalent to Trim(c, last=8) clip[1::2] #equivalent to selecting all frames with odd numbers clip[::-1] # Reverse(c) Interleave([clip[::2], clip[1::2]]) # do "nothing" clip1[200::-5] + clip2[5:10:3] # ponder this one
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet Last edited by Myrsloik; 26th September 2012 at 11:29. |
26th September 2012, 15:44 | #215 | Link |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
You found the single case where I forgot to adjust the trim end appropriately (with only stop and not start set). I've reuploaded R9 with that small detail fixed.
Note that clip[0:9] will give you the correct result even in the broken version.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
26th September 2012, 16:29 | #216 | Link |
Registered User
Join Date: Jul 2010
Posts: 448
|
Trying to do some temporal scripting. Couple of queries:
- SelectEvery fails if any selected frame is negative (doesn't seem to be so much a problem at the clip end...?). Avisynth duplicates the start/end frames, so allowing "out-of-cycle" offsets. This is used by many avisynth scripts. Without it, temporal processing at the clip ends becomes trickier. - Related, SelectEvery does not accept a cycle of 1. For selecting the clip offset by a number of frames: SelectEvery(c,1,[-2]) - Negative slice start and end values? I thought they counted from the end of the sequence. Seems to reject them here. Exacerbates the above two points because the workarounds involve padding at the start and the end. - Suggestion: * operator for clip repetition. c * 2 = clip repeated twice. Last edited by -Vit-; 26th September 2012 at 16:36. |
26th September 2012, 17:08 | #217 | Link | |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
Quote:
Also, negative offsets in slicing is just crazy. It goes against all that is good and python. Use clip[clip.num_frames - 10, clip.num_frames - 5, -1] If you need something similar. I intentionally kept trim simple. Look at the mess in avisynth and you'll see why. I'll think about a repeat operator but it's a lot less common for someone to need it. I want to keep it simple and avoid operator overloading hell.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
|
26th September 2012, 18:56 | #218 | Link | |
Registered User
Join Date: Jul 2010
Posts: 448
|
I'm was trying to do a 2-radius temporal smooth in script for TGMC. The trick is the clip ends, where there aren't enough frames. Naturally I started with the avisynth approach because it deals with that trivially; and there are no complex vapoursynth script examples - you gotta start somewhere.
Quote:
It's useful for the padding needed at the ends of the clip I needed to implement the above. I guess it can be done with slice+loop. But you go against expectations by providing some list operators and not others (I immediately went for the * operator and I'm not a Pythoner) |
|
26th September 2012, 19:03 | #219 | Link | |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
Quote:
As for scripts I suggest you post a few lines of avisynth script here and I'll tell you how it'd write it. I'm actually surprised so few people ask me about the syntax.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
|
27th September 2012, 21:54 | #220 | Link |
Registered User
Join Date: Sep 2006
Posts: 1,657
|
ok i'lve read all 12 pages of this thread, and i have the script ready in a py file. But how do you run it with different codec like xvid, divx and x264? I mean how do I write it in the command window? And how do I measure the speed of each filters without outputing the video file?
And there's no link in the documentation page that redirect back to the homepage Last edited by lansing; 27th September 2012 at 21:57. |
Tags |
speed, vaporware, vapoursynth |
|
|