Are image morphological operations invalid for RGB images?
4 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Matthew Eicholtz
le 10 Oct 2015
Commenté : Image Analyst
le 10 Oct 2015
Most (if not all) of the morphological operations (e.g. imdilate, imerode, imtophat, imbothat) specify that the input image should be grayscale or binary. However, using an RGB image does not yield an error. Why is this? Is it ill-advised to use these functions with RGB (or other 3D) images?
0 commentaires
Réponse acceptée
Image Analyst
le 10 Oct 2015
It treats it like a 3D volumetric image, like a CT or MRI image, not like a 2D color image. However, it can operate color plane - by - color plane like I think you want, if you give it a kernel that is flat (no extent in the Z direction). You just have to know what you're doing. Usually doing morphological operations on the RGB color channels does not make sense and can produce color artifacts, whereas for a volumetric image it does make sense.
2 commentaires
Image Analyst
le 10 Oct 2015
Well if it works and you're happy with the results, then fine. But you may find that how well objects "survive" that filtering very much depends on the relative size of your object and your filtering window width. You may also find some share artifacts and some extra noise than some other methods might give. The bottom hat filter is the morphological closing minus the original image. Basically it's assuming the local max will be the background image and this can be noisier than say, fitting a smoothed or regression function. But it's easy, and if it works, then use it.
Plus de réponses (0)
Voir également
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!