[Mp4-tech] question ME algorithm

Tourapis Alexandros alexandros.tourapis thomson.net
Tue Dec 9 11:26:07 EST 2003


Dear Michael,
The main reason why this is happening is because your implementation does not consider any Rate Distortion Optimization techniques during the motion estimation phase. It is well known that a joint consideration of not only the distortion (SAD or MSE) but also the bits required to code the motion vectors (and if possible the bits required to code the residual although this is much harder to do within motion estimation and is mainly done in some implementations only for mode decision) can considerably improve your performance. In addition this consideration helps FS and other algorithms in achieving a more reliable and smooth motion field leading to better results. If you do not use this concept then FS can find the minimum at very odd positions and the penalty for coding motion vectors could end up being too high. Other algorithms that are more center biased could in such cases lead to better results than FS, but of course these algorithms would fail if you use high motion sequences and high bitrates (you never mentioned btw your bitrate and it is also true that this effect would be stronger at very low bitrates). There are of course new more advanced algorithms that can perform similar to FS no matter what (you may check the paper I mentioned or newer papers on the same topic).  I would recommend you though to read the following paper :
G. Sullivan and T. Wiegand, "Rate-distortion optimization for video compression," IEEE Signal Processing Magazine, vol. 15, no. 6, November 1998, pp. 74-90.
About the SAD instead of the MSE, although this could of course imply a difference in PSNR, its impact is more subtle compared to the above reason (no consideration of mv correlation). 
In any case my suggestion is, if you cannot implement any RD criteria in your encoder, also try different sequences (my recommendations is to use stefan, foreman, bus, kayak, coastguard etc from the mpeg sequences instead of low activity ones), different frame rates (do not always stick with 30 fps (if you are) but also try lower frame rates, and different (higher) bitrates. Just for reference, FSS and 2D-Log are in general very poor algorithms especially under such conditions.
Alexis
-----Original Message-----
From: Wang Hui [mailto:wangh china.com]
Sent: Tuesday, December 09, 2023 8:04 AM
To: Allen H.-Y. Chin
Cc: MP4-Tech
Subject: Re: [Mp4-tech] question ME algorithm
Dear Allen¡G
Thank you for your email.
I understood what you said, 
Sometime when the sequence with low motion, the FS maybe the worst one.I think Whether need to modify the PSNR computing method, in order to keep the criterion consistent.When FS is worst, how to know that the algorithm implementation is wrong or duing to PSNR computing?
best regards
Michael
----- Original Message ----- 
From: "Allen H.-Y. Chin" <hychin swallow.ee.nctu.edu.tw>
To: "Wang Hui" <wangh china.com>
Cc: "MP4-Tech" <MP4-Tech lists.mpegif.org>
Sent: Monday, December 08, 2023 7:49 PM
Subject: Re: [Mp4-tech] question ME algorithm
> Michael,
> 
> Sometimes I get slightly better PSNR results by switching to fast ME
> algorithm in MPEG-4 VM.
> 
> In VM18 by microsoft, the matching criterion for ME is SAD (sum of
> absolute difference).
> However, SSD (sum of square difference) is used in computing PSNR.
> Thus, a best-matched reference block found by ME using SAD does not
> guarantee minimum PSNR.
> 
> e.g.
> 5+6 > 1+9
> 5^2 + 6^2 < 1^2 + 9^2
> 
> Regards,
> Allen
> 

_______________________________________________
Mp4-tech mailing list
Mp4-tech lists.mpegif.org
http://lists.mpegif.org/mailman/listinfo/mp4-tech
Note: Conduct on the mailing list is subject to the Antitrust guidelines found at http://www.mpegif.org/public/documents/vault/mp-out-30042-Antitrust.php


More information about the Mp4-tech mailing list