Viewing contents of file '../idllib/astron/contrib/varosi/code/allpro/de_stripe_2.pro'
function de_stripe, image
;Eliminate the even/odd channel amplifier variation (vertical stripes) by
; averaging adjacent pixels (2x2 box-car smoothing),
; and then shifting image by -1/2 pixel to maintain original positions.
;Note that resolution is then degraded from 1x1 to 2x2 pixels.
;Frank Varosi STX @ NASA/GSFC 1992
sim = size( image )
if (sim(0) NE 2) then begin
message,"need an image (2-D matrix)",/INFO
return, image
endif
imf = ( image + shift( image,1,0 ) )/2.
imf(0,sim(2)-1) = image(*,sim(2)-1)
imf(sim(1)-1,0) = image(sim(1)-1,*)
return, imf
;;return, frac_pix_shift( imf, -0.5, 0 )
end