Borrar filtros
Borrar filtros

how to divide image into 5*5 blocks

1 visualización (últimos 30 días)
Mahmoud Hassan
Mahmoud Hassan el 13 de En. de 2019
Comentada: Walter Roberson el 26 de En. de 2019
hello, i have a binarized image of fingerprint that i want to divide into 5*5 blocks and then count the number of zeros " black points " in each block
thanks in advance

Respuesta aceptada

Walter Roberson
Walter Roberson el 13 de En. de 2019
Editada: Walter Roberson el 13 de En. de 2019
blockproc(YourImage, [5 5], @(block) nnz(~block.data), 'trimborder', false)
  34 comentarios
Walter Roberson
Walter Roberson el 26 de En. de 2019
You should post a new Question with details showing how you rotate. It is not related to this Question as this question does not involve rotation.

Iniciar sesión para comentar.

Más respuestas (1)

Matt J
Matt J el 14 de En. de 2019
Editada: Matt J el 14 de En. de 2019
A more efficient method than blockproc or mat2cell is to use sepblockfun (Download),
result = sepblockfun(~yourImage,[60,60],'sum');
This assumes that yourImage divides evenly into 60x60 blocks (if not, you should zero pad).

Categorías

Más información sobre Blue en Help Center y File Exchange.

Etiquetas

Productos


Versión

R2014b

Community Treasure Hunt

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

Start Hunting!

Translated by