Complexity of medfilt2 implementation in Matlab?

5 views (last 30 days)
We've got some computing time issues while invoking medfilt2. I spent successfully some time on finding several approaches for optimizing exactly this operation. Unfortunately, this information is kind of useless as I cannot find the complexity (or the implementation's basic approach) for the Matlab medfilt2 function.
Has anybody got any idea what the Matlab implementation's performance might be or alternatively, what algorithm it is based on?! (The documentation does not contain any of these information, nor can I find alternative implementations on File Exchange).

Accepted Answer

Jiro Doke
Jiro Doke on 5 Apr 2011
Did you check out the reference paper indicated at the end of the page for medfilt2? It also says it uses ordfilt2 to perform the filtering, and there are a couple of reference papers for that too.
  1 Comment
Pierre
Pierre on 5 Apr 2011
Gee, I missed the references completely as I only read quickly over the in-CLI-help and not the 'doc' before trying to google an answer. Quite embarrassing!
Those were exactly what I was looking for. After taking a look at them, I guess that in our case it would be worthless to implement any of the latest published optimisations for 2d median filtering ourselves, as as far as I know latter improve performance only for very large filters exceeding 50x50px.
Thank you very much.

Sign in to comment.

More Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!