[Python] Apply mask before computing metrics between 2 images with skimage

Discussão em 'Python' iniciado por Stack, Julho 21, 2025.

  1. Stack

    Stack Membro Participativo

    I am comparing in Python, 2 images A and B by computing various metrics with skimage.measure module, Let's say for example the structural similarity index with compare_ssim(A, B).

    I would like to apply a binary mask image C, to only take into account array indexes where the C mask is different to zero when computing metrics between A and B.

    Is there a way to apply this mask with skimage.measure (or any other module), or do I have to reimplement those metrics myself to do it ?

    Thank you !

    Continue reading...

Compartilhe esta Página