HW5_solution - EE4414 Multimedia Communication System II,...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
EE4414 Multimedia Communication System II, Fall 2005, Yao Wang Homework 5 Solution (Motion estimation for video coding) ___________________________________________________________________________________ 1. Describe the major steps of EBMA algorithms with integer-pel accuracy, either in the form of a pseudo C-code, or matlab code, or flow graph. Pseudo code in MATLAB style: %frame size: fheight,fwidth %block size: bheight, bwidth %search range: hsrange, vsrange %vMV_field, hMV_field: store the vertical and horizontal MVs MV_field_height=floor(fheight/bheight); MV_field_width=floor(fwidth/bwidth); vMV_field=zeros(MV_field_height,MV_field_width); hMV_field=zeros(MV_field_height,MV_field_width); MAX_SAD=255*bheight*bwidth; %for every block in the anchor frame, left corner at (r,c) for (r=1:bheight:fheight) for (c=1:bwidth:fwidth) %initialize SAD_min=MAX_SAD;vMV=0,hMV=0; anchor_block=anchor_frame(r:r+bheight-1,c:c+bwidth-1); %for every candidate_block_position_in_search_range, %left corner at (sr,sc) %increment by 1 pixel to left or down for (sr=r-vsrange:1:r+vsrange) for (sc=c-hsrange:1:c+hsrange) candidate_block= target_frame(sr:1:sr+bheight-1,sc:1:sc+bwidth-1); SAD=calculate_SAD(anchor_block,candidate_block); if SAD<SAD_min SAD_min=SAD; vMV=sr-r; hMV=sc-c; end; end; end; blk_r=floor(r/bheight);blk_c=floor(c/bwidth); vMV_field(blk_r,blk_c)=vMV; hMV_field(blk_r,blk_c)=hMV; predicted_frame(r:r+bheight-1,c:c+bwidth-1)=candidate_block; end;
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
end; 2. For a video of 30 frame/second, 352x288/frame, what is the number of operations needed per second to accomplish EBMA if we use block size of 16x16, search range of –16 to 16? (count
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 01/22/2012 for the course EE 4414 taught by Professor Wang during the Fall '07 term at NYU Poly.

Page1 / 4

HW5_solution - EE4414 Multimedia Communication System II,...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online