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. |
|
|
Thread Tools | Search this Thread | Display Modes |
28th April 2012, 21:12 | #61 | Link |
Registered User
Join Date: Mar 2005
Posts: 50
|
Hi chainik_svp,
would you mind explaining how to translate this standard MDegrain2 call in order to take advantage of your plugins? Code:
AviSource("something.avi") super = MSuper(pel=2, sharp=1) backward_vec2 = MAnalyse(super, isb = true, delta = 2, overlap=4) backward_vec1 = MAnalyse(super, isb = true, delta = 1, overlap=4) forward_vec1 = MAnalyse(super, isb = false, delta = 1, overlap=4) forward_vec2 = MAnalyse(super, isb = false, delta = 2, overlap=4) MDegrain2(super, backward_vec1,forward_vec1,backward_vec2,forward_vec2,thSAD=400) Code:
AviSource("something.avi") super = SVSuper("{pel:2, gpu:1}") vectors = SVAnalyse(super, "{gpu:1,block:{w:8,h:8,overlap:2}}") forward_mv = SVConvert(vectors, false) backward_mv = SVConvert(vectors, true) super_mv = MSuper(pel=1, hpad=0, vpad=0) MDegrain1(super_mv, backward_mv, forward_mv, thSAD=400) Can you please point me to the right direction? Thanks |
28th April 2012, 22:07 | #62 | Link | |
Registered User
Join Date: Mar 2012
Location: Saint-Petersburg
Posts: 239
|
Quote:
Again, I'm not trying to completely replace MVTools, so MDegrain and other things are not in my interests now But it's not a big deal to add "delta" param so if someone thinks it'll be useful I could do that. Last edited by chainik_svp; 28th April 2012 at 22:16. |
|
28th April 2012, 23:40 | #63 | Link |
Registered User
Join Date: Jul 2010
Posts: 448
|
My delta=2 method works fine, but don't try to simplify the fVec2 line, I believe it would be an error:
Code:
fVec2 = Interleave(vecs2e.SVConvert( isb=false ), vecs2o.SVConvert( isb=false )) # Correct fVec2 = Interleave(vecs2e, vecs2o).SVConvert( isb=false ) # Error --- For delta=3 do this: Code:
params_string = "{gpu:0}" # plus any other SVAnalyse settings vecs30 = super.SelectEvery(3,0).SVAnalyse( params_string ) vecs31 = super.SelectEvery(3,1).SVAnalyse( params_string ) vecs32 = super.SelectEvery(3,2).SVAnalyse( params_string ) fVec3 = Interleave( vecs30.SVConvert(isb=false), vecs31.SVConvert(isb=false), vecs32.SVConvert(isb=false) ) bVec3 = Interleave( vecs30.SVConvert(isb=true ), vecs31.SVConvert(isb=true ), vecs32.SVConvert(isb=true ) ) And here's a function to generate MVTools vectors using SVAnalyse and an arbitrary delta. It requires GScript. I've only tested it a little: Code:
# Use SVAnalyse with a given delta and convert vectors to MVTools format # Returns a single vector clip containing interleaved forward and backward vectors. # Example: # vec3 = super.SVAnalyseConvert( 3, "{gpu:0, pel:2}" ) # delta=3 # fVec3 = vec3.SelectEven() # bVec3 = vec3.SelectOdd() # function SVAnalyseConvert( clip super, int "delta", string "params_string" ) { delta = default(delta, 1) params_string = default(params_string, "{gpu:0}") GScript(""" if (delta == 1) { vecs = super.SVAnalyse( params_string ) return Interleave( vecs.SVConvert(isb=false), vecs.SVConvert(isb=true) ) } else { cf = "" cb = "" sD = string(delta) for (i=0, delta-1) { sI = string(i) Eval( "vecs"+sD+sI+"=super.SelectEvery("+sD+","+sI+").SVAnalyse( params_string )" ) cf = cf + "vecs"+sD+sI+".SVConvert(isb=false)" cb = cb + "vecs"+sD+sI+".SVConvert(isb=true)" if (i != delta-1) { cf = cf + "," cb = cb + "," } } return Eval( "Interleave(Interleave("+cf+"),Interleave("+cb+"))" ) } """) } And yes, I guess a delta parameter would be nice! Last edited by -Vit-; 28th April 2012 at 23:45. |
2nd May 2012, 12:09 | #65 | Link | |
Registered User
Join Date: Mar 2012
Location: Saint-Petersburg
Posts: 239
|
Quote:
|
|
2nd May 2012, 12:42 | #66 | Link |
Registered User
Join Date: Mar 2012
Location: Saint-Petersburg
Posts: 239
|
-Vit-
I guess a delta parameter would be nice! Ver. 1.0.4 look at special.delta param in SVAnalyse Code:
{block:{...}, main:{...}, refine:{...}, special:{delta:2}} |
2nd May 2012, 14:53 | #67 | Link |
Registered User
Join Date: Jan 2012
Location: Toulon France
Posts: 251
|
Hi Chainik,
I apologize, my Refine line is not with whole default values. But always output for this SVAnalyse( super, """{ gpu: 0, vectors: 3, block: { w: 16, h: 16, overlap: 0 }, main: { levels: 0, search: { type: 4, distance: -10, sort: true, satd: false, coarse: { type: 4, distance: -10, satd: true, trymany: false, bad: { sad: 1000, range: -24 } } }, penalty: { lambda: 10.0, plevel: 1.5, lsad: 8000, pnew: 50, pglobal: 50, pzero: 100, pnbour: 50, prev: 0 } } , refine: [ { thsad: 200, search: { type: 4, distance: 2, satd: false }, penalty: { pnew: 50 } } ] }""") is not same as output for this SVAnalyse( super, """{ gpu: 0, vectors: 3, block: { w: 16, h: 16, overlap: 0 }, main: { levels: 0, search: { type: 4, distance: -10, sort: true, satd: false, coarse: { type: 4, distance: -10, satd: true, trymany: false, bad: { sad: 1000, range: -24 } } }, penalty: { lambda: 10.0, plevel: 1.5, lsad: 8000, pnew: 50, pglobal: 50, pzero: 100, pnbour: 50, prev: 0 } } }""") Bernard Last edited by Bernardd; 2nd May 2012 at 15:02. |
2nd May 2012, 16:49 | #69 | Link |
Registered User
Join Date: Jan 2012
Location: Toulon France
Posts: 251
|
Thank Chainik,
I apologize, I have not understand fast. Now it is OK. Second question, when i restore old Super 8 movies to return Framerate from 16.667 fps to 25, i have tried "plevel = 10" with algo 23 for minimize blend. What it is the max plevel value usable ? Bernard |
3rd May 2012, 09:15 | #70 | Link |
Registered User
Join Date: Mar 2012
Location: Saint-Petersburg
Posts: 239
|
Bernardd
What it is the max plevel value usable ? I've got no idea But this extremely high "plevel" value means almost zero lambda penalty on all levels except smallest one which leads to less coherent vectors field. |
3rd May 2012, 11:12 | #71 | Link | |
Registered User
Join Date: Mar 2012
Location: Saint-Petersburg
Posts: 239
|
Version 1.0.5
Quote:
|
|
8th May 2012, 17:42 | #73 | Link | |
Pig on the wing
Join Date: Mar 2002
Location: Finland
Posts: 5,799
|
Quote:
And thanks for all your hard work, there is never too much development these days
__________________
And if the band you're in starts playing different tunes I'll see you on the dark side of the Moon... |
|
8th May 2012, 21:14 | #74 | Link | |
Registered User
Join Date: Mar 2012
Location: Saint-Petersburg
Posts: 239
|
Quote:
thanks for all your hard work, there is never too much development these days thanks! Last edited by chainik_svp; 8th May 2012 at 22:16. |
|
11th May 2012, 03:30 | #75 | Link | |
Registered User
Join Date: Nov 2006
Posts: 779
|
I haven't tried svp yet but i'd be intereted as it us the gpu; basically i want to replace the mvtools part in my script how would i code that ?
my script: Quote:
|
|
11th May 2012, 16:58 | #78 | Link |
Registered User
Join Date: Mar 2012
Location: Saint-Petersburg
Posts: 239
|
Compared with what? With the original Fizick's 2.5.11.3 - yes, with the version from SVP 3.0.6 - not really (except SVPflow has "adaptive search radius" feature of cause).
Mounir Do you really need "dct=2" and different search options for forward and backward MVs? If not then central part of the script could be something like this: Code:
sup1 = clean1.minblur(1).removegrain(11,0).removegrain(11,0) \ .mt_lutxy(clean1,"x 1 + y < x 2 + x 1 - y > x 2 - y ? ?",U=2,V=2) \ .SVSuper("pel:2, scale:{up:0}") search_params="block:{w:8,overlap:3}" #or whatever v21=sup1.SVAnalyse("{"+search_params+"}") v22=sup1.SVAnalyse("{"+search_params+",special:{delta:2}}") bv22=v22.SVConvert(isb=true) bv21=v21.SVConvert(isb=true) fv21=v21.SVConvert(isb=false) fv22=v22.SVConvert(isb=false) sup2 = a.msuper(pel=2,levels=1,sharp=2) interleave(a.mcompensate(sup2,fv22),a.mcompensate(sup2,fv21),a,a.mcompensate(sup2,bv21),a.mcompensate(sup2,bv22)) selectevery(5,2) sup3 = last.msuper(pel=2,sharp=2,hpad=0,vpad=0) # SVAnalyse accepts MSuper with zero padding! v31=sup3.SVAnalyse("{"+search_params+"}") v32=sup3.SVAnalyse("{"+search_params+",special:{delta:2}}") v33=sup3.SVAnalyse("{"+search_params+",special:{delta:3}}") bv33=v33.SVConvert(isb=true) bv32=v32.SVConvert(isb=true) bv31=v31.SVConvert(isb=true) fv31=v31.SVConvert(isb=false) fv32=v32.SVConvert(isb=false) fv33=v33.SVConvert(isb=false) last.mdegrain3(sup3,bv31,fv31,bv32,fv32,bv33,fv33,thSAD=499) Last edited by chainik_svp; 11th May 2012 at 17:28. |
11th May 2012, 20:15 | #80 | Link |
Registered User
Join Date: Mar 2012
Location: Saint-Petersburg
Posts: 239
|
o_O I thought it's your script.
Or you've just taken it from somewhere and you've got no idea how it works? In the last case I suggest to ask -Vit- for assistance with all this stuff like "delta" and mdegrain. Last edited by chainik_svp; 11th May 2012 at 20:18. |
Tags |
frame doubling, frame rate conversion, mvtools, opencl |
Thread Tools | Search this Thread |
Display Modes | |
|
|