VideoHelp Forum




+ Reply to Thread
Results 1 to 13 of 13
  1. Hello everyone,

    I have a footage of a live stage show, and it is quite shaky.
    I tried to use Deshaker to fix it, but the result was just... as shaky.
    Not sure what's wrong with it, here's the settings I used:

    *PASS 1
    Click image for larger version

Name:	Pass 1.jpg
Views:	323
Size:	164.7 KB
ID:	3304

    *PASS 2
    Click image for larger version

Name:	Pass 2.jpg
Views:	294
Size:	167.0 KB
ID:	3305

    And below, I have uploaded the sample clips:

    - Before:
    http://www.mediafire.com/file/pgn72fqlr7esnpq/Il%20Muto%20original.mpg
    - After:
    http://www.mediafire.com/file/sq5nbra5xhox3aw/Il%20Muto%20deshake.mpg

    I usually use Sony Vegas to do some simple edit, and luckily I've found a script to link Sony Vegas to Virtual Dub and Deshaker, so that everytime I want to deshake a clip, and I do it in Vegas.
    But maybe it has nothing to do with here :P

    I just want some advice from you (I'm just an amateur).
    What is the best possible in this case to improve the stableness of the clip?
    I have used Deshaker on other outdoor footage before, and I believe it can do better than this.
    Have I done something wrong with the settings?

    Any help would be greatly appreciated!
    Quote Quote  
  2. I am by no means an expert on using deshaker, but there 2 things that I am 100% sure of:

    1) deshaker works better with no black borders . You should crop the footage before inputing

    2) deshaker works better with progressive footage. There's pros/cons to deinterlacing, deshaking, then re-interlacing, and the arguments for either side are fairly solid. I will say that if you use a good avisynth deinterlacer, you will get better results overall on most footage

    You havent posted the other settings used pass 1&2 tab (interlaced, aspect ratio etc...)

    Consider using the edge compensation modes , because your "deshaken" video has fairly ugly edges IMO. Deshaker's edge compensation is one of the big features that sets it apart from other stabilizers

    There are a lot of tips on the author's homepage
    http://www.guthspot.se/video/deshaker.htm
    Quote Quote  
  3. Member pirej's Avatar
    Join Date
    Mar 2008
    Location
    Macedonia
    Search Comp PM
    I never used deshaker, but avisynth could help.
    Try this code, but maybe you should increase maxstabH/V and crop value's.
    Code:
    LoadPlugin(\\"C:\Program Files\AviSynth 2.5\plugins\DePan.dll\\")
    LoadPlugin(\\"C:\Program Files\AviSynth 2.5\plugins\DePanEstimate.dll\\")
    #v1=MPEG2Source(\\"C:\Desktop\stab test\Il Muto original.d2v\\", cpu=0)
    V=MPEG2Source(\\"C:\Desktop\stab test\Il Muto original.d2v\\", cpu=0).AssumeBFF().SeparateFields()
    
    #SIZE, CROP AND BORDERS PARAMETERS
    #----------------------------------------------------------------------------------------------------------------------------
    CLeft=6  CTop=4  CRight=4  CBottom=6  #crop values after Depan and before final resizing 
    W=720  H=240 #final size after cropping 
    
    #STABILISING PARAMETERS
    #----------------------------------------------------------------------------------------------------------------------------
    maxstabH=20 
    maxstabV=20 #maximum values for the stabiliser (in pixels), 20 is a good start value
    est_left=20   est_top=20  est_right=20  est_bottom=20  est_cont=1.0  #crop and contast values for special Estimate clip
    #--------------
    source1= v
    #STABILIZING
    #....................................................................................................................................................................
    stab_reference= source1.crop(est_left,est_top,-est_right,-est_bottom).tweak(cont=est_cont).MT_binarize(threshold=80).greyscale().invert()
    
    mdata=DePanEstimate(stab_reference,trust=1.0,dxmax=maxstabH,dymax=maxstabV)
    stab=DePanStabilize(source1,data=mdata,cutoff=0.5,dxmax=maxstabH,dymax=maxstabV,method=1,mirror=15)
    stab2= stab.crop(CLeft,CTop,-CRight,-CBottom).deflicker(border=20)
    stab3=DePanStabilize(source1,data=mdata,cutoff=0.5,dxmax=maxstabH,dymax=maxstabV,method=1,info=true)
    
    WS= width(stab)
    HS= height(stab)
    stab4= stab3.addborders(10,10,10,10,$B1B1B1).Lanczos4Resize(WS,HS)
    stab5= Lanczos4Resize(stab2,W,H)#.sharpen(0.5)
    
    Stabilized=stab5.AssumeBFF().AssumeFieldBased().Weave()
    #........................................................
    #StackHorizontal(v1,Stabilized)
    Return Stabilized
    Quote Quote  
  4. Originally Posted by poisondeathray View Post
    I am by no means an expert on using deshaker, but there 2 things that I am 100% sure of:

    1) deshaker works better with no black borders . You should crop the footage before inputing

    2) deshaker works better with progressive footage. There's pros/cons to deinterlacing, deshaking, then re-interlacing, and the arguments for either side are fairly solid. I will say that if you use a good avisynth deinterlacer, you will get better results overall on most footage

    You havent posted the other settings used pass 1&2 tab (interlaced, aspect ratio etc...)

    Consider using the edge compensation modes , because your "deshaken" video has fairly ugly edges IMO. Deshaker's edge compensation is one of the big features that sets it apart from other stabilizers

    There are a lot of tips on the author's homepage
    http://www.guthspot.se/video/deshaker.htm
    Thanks for the suggestion.
    Yes the edges are ugly :P
    I choose Edge Compensation: None (Large Borders) in Deshaker, because when I'm satisfied with the result, I can use Vegas to crop it later.
    The Fixed Zoom option is not really useful with long clips, the pictures keep zooming in and out
    Quote Quote  
  5. Originally Posted by pirej View Post
    I never used deshaker, but avisynth could help.
    Try this code, but maybe you should increase maxstabH/V and crop value's.
    Thanks a lot. I have never used Avisynth, but after hearing so many good words about, maybe I will give it a try
    Quote Quote  
  6. Originally Posted by namphong0612 View Post

    I choose Edge Compensation: None (Large Borders) in Deshaker, because when I'm satisfied with the result, I can use Vegas to crop it later.
    The Fixed Zoom option is not really useful with long clips, the pictures keep zooming in and out
    By cropping (and presumably upscaling later to fill the frame size), you are losing active image area - i.e. you're losing pixels

    Deshaker has ability to use information from past & future frames to fill those edge pixels, it's uncheckmarked in your screenshot - but it works well in most cases.

    You can use the adaptive zoom or adaptive + fixed combination. If you use it in vdub, you can preview the result after the analysis pass

    Also, what are your expectations? Deshaker just "smooths" everything over. It's not a stabilizer meant for rigid shots (as if shot on a tripod or locked down shot)
    Quote Quote  
  7. When video has a lot of dark background I find it helps to set Scale to Full, and Use Pixels to All -- it looks like you've used those settings. I would also turn off Detect Zoom and Detect Rotation. I just tried it on your clip and it worked pretty well. As poisondeathray pointed out, at default settings it does not remove the low frequency wandering, just the high frequency shakes. If you crank the Smoothness settings up to 10000 a lot of the wandering will go away.

    Note a new version of DeShaker for VirtualDub was released just a week or two ago.
    Last edited by jagabo; 30th Aug 2010 at 18:09.
    Quote Quote  
  8. Member
    Join Date
    Dec 2010
    Location
    quebec
    Search Comp PM
    would doing 2 complete passes of deshaker ((analysis+encode)X2) blur too much ?
    Quote Quote  
  9. The video will get less sharp with each use of deshaker. I don't imagine multiple deshaker passes will do anything that can't be done with a single pass and "wider" settings.
    Quote Quote  
  10. Member
    Join Date
    Dec 2010
    Location
    quebec
    Search Comp PM
    ouch 9h analysis and 9h encoding for 25 min clip
    Quote Quote  
  11. Member
    Join Date
    Dec 2010
    Location
    quebec
    Search Comp PM
    i tried your script and modified theses lines :

    AVISource("G:\FNM\FNM_Jam06.avi", audio=true).AssumeFPS(30.000).Converttoyv12()
    V=AVISource("G:\FNM\FNM_Jam06.avi", audio=true).AssumeFPS(30.000).Converttoyv12()

    on a progressive source and gave me 15 fps ... how come ?


    Originally Posted by pirej View Post
    I never used deshaker, but avisynth could help.
    Try this code, but maybe you should increase maxstabH/V and crop value's.
    Code:
    LoadPlugin(\\"C:\Program Files\AviSynth 2.5\plugins\DePan.dll\\")
    LoadPlugin(\\"C:\Program Files\AviSynth 2.5\plugins\DePanEstimate.dll\\")
    #v1=MPEG2Source(\\"C:\Desktop\stab test\Il Muto original.d2v\\", cpu=0)
    V=MPEG2Source(\\"C:\Desktop\stab test\Il Muto original.d2v\\", cpu=0).AssumeBFF().SeparateFields()
    
    #SIZE, CROP AND BORDERS PARAMETERS
    #----------------------------------------------------------------------------------------------------------------------------
    CLeft=6  CTop=4  CRight=4  CBottom=6  #crop values after Depan and before final resizing 
    W=720  H=240 #final size after cropping 
    
    #STABILISING PARAMETERS
    #----------------------------------------------------------------------------------------------------------------------------
    maxstabH=20 
    maxstabV=20 #maximum values for the stabiliser (in pixels), 20 is a good start value
    est_left=20   est_top=20  est_right=20  est_bottom=20  est_cont=1.0  #crop and contast values for special Estimate clip
    #--------------
    source1= v
    #STABILIZING
    #....................................................................................................................................................................
    stab_reference= source1.crop(est_left,est_top,-est_right,-est_bottom).tweak(cont=est_cont).MT_binarize(threshold=80).greyscale().invert()
    
    mdata=DePanEstimate(stab_reference,trust=1.0,dxmax=maxstabH,dymax=maxstabV)
    stab=DePanStabilize(source1,data=mdata,cutoff=0.5,dxmax=maxstabH,dymax=maxstabV,method=1,mirror=15)
    stab2= stab.crop(CLeft,CTop,-CRight,-CBottom).deflicker(border=20)
    stab3=DePanStabilize(source1,data=mdata,cutoff=0.5,dxmax=maxstabH,dymax=maxstabV,method=1,info=true)
    
    WS= width(stab)
    HS= height(stab)
    stab4= stab3.addborders(10,10,10,10,$B1B1B1).Lanczos4Resize(WS,HS)
    stab5= Lanczos4Resize(stab2,W,H)#.sharpen(0.5)
    
    Stabilized=stab5.AssumeBFF().AssumeFieldBased().Weave()
    #........................................................
    #StackHorizontal(v1,Stabilized)
    Return Stabilized
    Quote Quote  
  12. Member
    Join Date
    Jul 2009
    Location
    Spain
    Search Comp PM
    Originally Posted by smartel View Post
    i tried your script and modified theses lines :

    AVISource("G:\FNM\FNM_Jam06.avi", audio=true).AssumeFPS(30.000).Converttoyv12()
    V=AVISource("G:\FNM\FNM_Jam06.avi", audio=true).AssumeFPS(30.000).Converttoyv12()

    on a progressive source and gave me 15 fps ... how come ?
    I assume you mean you changed this line:
    Code:
    V=MPEG2Source(\\"C:\Desktop\stab test\Il Muto original.d2v\\", cpu=0).AssumeBFF().SeparateFields()
    to this:
    Code:
    V=AVISource("G:\FNM\FNM_Jam06.avi", audio=true).AssumeFPS(30.000).Converttoyv12()
    In that case, you also need to change this line:
    Code:
    Stabilized=stab5.AssumeBFF().AssumeFieldBased().Weave()
    to this:
    Code:
    Stabilized=stab5
    In other words, since you are no longer separating the fields, you need to remove the weave operation which puts them back together (and halves the frame rate).
    Quote Quote  
  13. Member
    Join Date
    Dec 2010
    Location
    quebec
    Search Comp PM
    ohhh i think i'll have to resize that somehow

    in my preview, my frames have lost half of it's vertical resolution
    the scipts is made for fields (720x240 ) not whole frames (720v480)

    so my first wyld guess is to change :

    W=720 H=240 #final size after cropping

    to

    W=720 H=480


    trouble compressing with huffy utput compressor error , source image format is not acceptable code -2

    works with mjpeg ....
    Last edited by smartel; 11th Jan 2012 at 22:25.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!