Naked Science Forum

Non Life Sciences => Geek Speak => Topic started by: syhprum on 05/01/2014 16:27:40

Title: Removing camera shake
Post by: syhprum on 05/01/2014 16:27:40
Has anyone any experience with Photoshop/Piccure I have been trying to get some results from a badly shaken shot with little results.
Title: Re: Removing camera shake
Post by: RD on 05/01/2014 18:16:18
The "sharpen" effects in photo-manipulation programs like photoshop is only useful for correcting subtle blurriness : digital sharpening would only of use if the blur due to camera shake was less than 1/1000th the diagonal measurement of the frame.

This is the modest improvement in sharpness which is possible ...

 [ Invalid Attachment ]

Better results are possible with blurry video : a still image which is average of hundreds of video frames can be created which is astonishingly sharp ...
Title: Re: Removing camera shake
Post by: syhprum on 05/01/2014 18:45:45
Piccure is a separate program intended to deal with severe camera shake it operates as a plugin in addition to the normal range of sharpening routines provided by Photoshop.
Title: Re: Removing camera shake
Post by: RD on 05/01/2014 20:35:55
Piccure is a separate program intended to deal with severe camera shake ...

The phrase Piccure use is "micro-shake reduction" ... http://www.piccure.de/index.php/en/product-eng
Their before-after images don't look much better that the example I posted above which is a free sharpen plugin for the photo-editor GIMP (http://en.wikipedia.org/wiki/GIMP) , (which does have a built-in sharpen function which isn't quite as good).

I've done a comparison of GIMP Vs PICCURE sharpening (attached) ,
[ I think I can justify the use of the PICCURE image under fair use (http://en.wikipedia.org/wiki/Fair_use) : commentary / criticism ].
Title: Re: Removing camera shake
Post by: syhprum on 05/01/2014 22:36:55
I was trying to make sense of this badly shaken picture. actually I worked with the .BMP version but that was too large to transmit.
Thank you for your interest I will try Gimp tomorrow but I think it is asking too much!
Title: Re: Removing camera shake
Post by: RD on 05/01/2014 23:22:39
I was trying to make sense of this badly shaken picture ... * test.pdf (31.43 kB)

GIMP won't be able to sharpen that, I don't know of anything that will.
The light trails caused by the camera shake are clearly visible ...

 [ Invalid Attachment ]

Maybe if you used the image-stacking (http://en.wikipedia.org/wiki/Registax) technique I mentioned earlier , making a series of images by shifting the original image according to the light trail, then creating an average of those series of images     [?] 

[ although the musicians look like they have moved during the exposure and even if undoing the camera shake were possible , it won't undo the musician's motion blur ]

I think you're stuck with an impressionistic image there.
Title: Re: Removing camera shake
Post by: syhprum on 06/01/2014 09:20:08
I realise it is probably impossible but I was inspired by some pictures of a phoney séance I had seen where a very blurred picture of a "spirit" appeared, after much digital reprocessing it was resolved as a stage hand running across the set!
Thanks again for your interest I have had various copies of Photoshop since 1985 but little skill in using it.
Title: Re: Removing camera shake
Post by: evan_au on 06/01/2014 09:30:36
Part of the difficulty in deblurring is working out what is the direction and extent of the blurring - and is it due to poor focus, chromatic aberration or motion blur.
However, in this case you seem to have this part of the problem solved - the main concern is motion blur, and the highlights on the drum kit (expanded above) track the position, duration and direction of the camera shake on a pixel-by-pixel basis!

As I understand it, you create a filter matrix which has the same dimensions as the blur (about 20x20pixels, in this case). Weights are placed in the cells of the matrix so that the output value of a pixel is the weighted average of the pixels that have been blurred from that point in the image, with negative weights on the other pixels which have been blurred into the same output pixel. Place zeros in the cells which do not contribute to the output pixel. The sum of the weights in all of the filter cells should be 1, so it doesn't make the entire picture brighter or darker.

This filter matrix is then positioned sequentially over every pixel position in the original image; multiply the pixel values in the original image by the values in the filter matrix to create one pixel in the output image.

It won't recover all of the image, as:

There are mathematical techniques to automatically extract some of the information about the extent & direction of blur from the image itself - but as I understand it, some of the information is irretrievably lost. So don't expect a result as good as your average TV Spy/Detective/Forensic Science drama.
Title: Re: Removing camera shake
Post by: RD on 06/01/2014 14:18:26
I've found free deconvolution (http://en.wikipedia.org/wiki/Deconvolution#Optics_and_other_imaging) software called IRIS , like REGISTAX it's designed for astro-photography ...

 [ Invalid Attachment ]
http://www.astrosurf.com/buil/us/iris/deconv/deconv.htm  (http://www.astrosurf.com/buil/us/iris/deconv/deconv.htm)

It may help in "light-trail" situations if it can be made to work with non-astronomical images. 

Database Error

Please try again. If you come back to this error screen, report the error to an administrator.
Back