SlideShare una empresa de Scribd logo
1 de 15
Descargar para leer sin conexión
UNIVERSIDAD NACIONAL PEDRO RUIZ GALLO
PROCESAMIENTO DIGITAL DE IMÁGENES
Mg. Ing. Oscar Ucchelly Romero Cortez
Curso:
Docente:
FACULTAD DE CIENCIAS FÍSICAS Y MATEMÁTICAS
Semestre 2022 – I
Procesamiento Digital de Imágenes
VECINDAD
Para determinar si dos pixeles son vecinos o no (adyacentes).
Vecindad 4:
Se considera pixeles conectados en direcciones perpendiculares
(arriba, abajo, derecha, izquierda).
Vecindad 8:
Se considera también los pixeles vecinos diagonales.
Procesamiento Digital de Imágenes
Procesamiento Digital de Imágenes
CONECTIVIDAD
Dos pixeles están con la misma etiqueta están conectados si existe un
camino del uno al otro a través de pixeles vecinos con la misma
etiqueta.
La conectividad puede ser:
Vecindad 4:
Se toma en cuenta la vecindad 4 para determinar la conectividad de
pixeles.
Vecindad 8:
Se toma en cuenta la vecindad 8 para determinar la conectividad de
pixeles.
Procesamiento Digital de Imágenes
CONECTIVIDAD
Etiquetado:
Agrupación de pixeles con características similares.
Si se elige conectividad conexión 4 se consideraría como dos objetos
diferentes, pero si se elige conectividad conexión 8 se consideraría
como un solo objeto (vecindad diagonal).
Procesamiento Digital de Imágenes
CONECTIVIDAD
Etiquetado:
Agrupación de pixeles con características similares.
Si se elige conectividad conexión 4 se consideraría como dos objetos
diferentes, pero si se elige conectividad conexión 8 se consideraría
como un solo objeto (vecindad diagonal).
Procesamiento Digital de Imágenes
CUENTA Y ETIQUETADO DE OBJETOS EN UNA IMAGEN
Para contar la cantidad de objetos presentes en una imagen se realiza
el procedimiento:
- Leer la imagen.
- Convertirla a escala de grises y luego binarizarla.
- En la imagen binarizada se requiere que los objetos a contar estén
en blanco (255) y con fondo negro (0), si no fuera el caso entonces
aplicar el comando:
IB = not (I)
Procesamiento Digital de Imágenes
CUENTA Y ETIQUETADO DE OBJETOS EN UNA IMAGEN
Para contar la cantidad de objetos presentes en una imagen se realiza
el procedimiento:
- Ejecutar el siguiente comando para etiquetar los objetos. Cada
objeto encontrado se etiqueta con un número entero: 1,2,3,….
IB_label = bwlabel(IB , C)
Donde:
C = 4 ó 8 (conexión)
- Para obtener el número de objetos:
n = max(max(IB_label))
Procesamiento Digital de Imágenes
EJEMPLO
¿Contabilizar el número de objetos de la siguiente imagen?
Procesamiento Digital de Imágenes
SOLUCIÓN
Procesamiento Digital de Imágenes
Procesamiento Digital de Imágenes
EJEMPLO
Para seleccionar el objeto seleccionado y se aisla en la matriz “IB_sele”
Procesamiento Digital de Imágenes
Procesamiento Digital de Imágenes
EJERCICIOS
Procesamiento Digital de Imágenes
EJERCICIOS

Más contenido relacionado

Último

Trabajo practico N°14 - Despacho Economico de Cargas - Campus 2022.pdf
Trabajo practico N°14 - Despacho Economico de Cargas - Campus 2022.pdfTrabajo practico N°14 - Despacho Economico de Cargas - Campus 2022.pdf
Trabajo practico N°14 - Despacho Economico de Cargas - Campus 2022.pdfChristianMOntiveros1
 
Video sustentación GA2- 240201528-AA3-EV01.pptx
Video sustentación GA2- 240201528-AA3-EV01.pptxVideo sustentación GA2- 240201528-AA3-EV01.pptx
Video sustentación GA2- 240201528-AA3-EV01.pptxcarlosEspaaGarcia
 
3er Informe Laboratorio Quimica General (2) (1).pdf
3er Informe Laboratorio Quimica General  (2) (1).pdf3er Informe Laboratorio Quimica General  (2) (1).pdf
3er Informe Laboratorio Quimica General (2) (1).pdfSantiagoRodriguez598818
 
Tema ilustrado 9.2.docxbbbbbbbbbbbbbbbbbbb
Tema ilustrado 9.2.docxbbbbbbbbbbbbbbbbbbbTema ilustrado 9.2.docxbbbbbbbbbbbbbbbbbbb
Tema ilustrado 9.2.docxbbbbbbbbbbbbbbbbbbbantoniolfdez2006
 
INFORME de pregrado ingenieria de vias.pdf
INFORME de pregrado ingenieria de vias.pdfINFORME de pregrado ingenieria de vias.pdf
INFORME de pregrado ingenieria de vias.pdfoctaviosalazar18
 
dokumen.tips_311-determinacion-del-espacio-estatico.pptx
dokumen.tips_311-determinacion-del-espacio-estatico.pptxdokumen.tips_311-determinacion-del-espacio-estatico.pptx
dokumen.tips_311-determinacion-del-espacio-estatico.pptxQualityAdviceService
 
TECNOLOGIA DE CONCRETO 2024 estudiante.pdf
TECNOLOGIA DE CONCRETO 2024 estudiante.pdfTECNOLOGIA DE CONCRETO 2024 estudiante.pdf
TECNOLOGIA DE CONCRETO 2024 estudiante.pdfEddieEDM
 
G4 - CASO DE ESTUDIO - VOLUMEN DE UN RESERVORIO (1).pptx
G4 - CASO DE ESTUDIO - VOLUMEN DE UN RESERVORIO (1).pptxG4 - CASO DE ESTUDIO - VOLUMEN DE UN RESERVORIO (1).pptx
G4 - CASO DE ESTUDIO - VOLUMEN DE UN RESERVORIO (1).pptxMaxPercyBorjaVillanu
 
Mantenimiento-de-Transformadores-Monofasicos[1].pptx
Mantenimiento-de-Transformadores-Monofasicos[1].pptxMantenimiento-de-Transformadores-Monofasicos[1].pptx
Mantenimiento-de-Transformadores-Monofasicos[1].pptxJasserGonzalez2
 
Tippens fisica 7eDIAPOSITIVAS TIPENS Tippens_fisica_7e_diapositivas_33.ppt
Tippens fisica 7eDIAPOSITIVAS TIPENS Tippens_fisica_7e_diapositivas_33.pptTippens fisica 7eDIAPOSITIVAS TIPENS Tippens_fisica_7e_diapositivas_33.ppt
Tippens fisica 7eDIAPOSITIVAS TIPENS Tippens_fisica_7e_diapositivas_33.pptNombre Apellidos
 
Arquitecto cambio de uso de suelo Limache
Arquitecto cambio de uso de suelo LimacheArquitecto cambio de uso de suelo Limache
Arquitecto cambio de uso de suelo LimacheJuan Luis Menares
 
ATS-FORMATOa.pdf PARA MANTENIMIENTO MECANICO
ATS-FORMATOa.pdf PARA MANTENIMIENTO MECANICOATS-FORMATOa.pdf PARA MANTENIMIENTO MECANICO
ATS-FORMATOa.pdf PARA MANTENIMIENTO MECANICOalejandrocrisostomo2
 
27311861-Cuencas-sedimentarias-en-Colombia.ppt
27311861-Cuencas-sedimentarias-en-Colombia.ppt27311861-Cuencas-sedimentarias-en-Colombia.ppt
27311861-Cuencas-sedimentarias-en-Colombia.pptjacnuevarisaralda22
 
ingenieria grafica para la carrera de ingeniera .pptx
ingenieria grafica para la carrera de ingeniera .pptxingenieria grafica para la carrera de ingeniera .pptx
ingenieria grafica para la carrera de ingeniera .pptxjhorbycoralsanchez
 
INTEGRATED PROJECT DELIVERY.pdf (ENTREGA INTEGRADA DE PROYECTOS)
INTEGRATED PROJECT DELIVERY.pdf (ENTREGA INTEGRADA DE PROYECTOS)INTEGRATED PROJECT DELIVERY.pdf (ENTREGA INTEGRADA DE PROYECTOS)
INTEGRATED PROJECT DELIVERY.pdf (ENTREGA INTEGRADA DE PROYECTOS)miguelbenito23
 
entropia y neguentropia en la teoria general de sistemas
entropia y neguentropia en la teoria general de sistemasentropia y neguentropia en la teoria general de sistemas
entropia y neguentropia en la teoria general de sistemasDerlyValeriaRodrigue
 
8 2024A CONDUCCION DE CALOR EN REGIMEN TRANSITORIO.pptx
8 2024A CONDUCCION DE CALOR EN REGIMEN TRANSITORIO.pptx8 2024A CONDUCCION DE CALOR EN REGIMEN TRANSITORIO.pptx
8 2024A CONDUCCION DE CALOR EN REGIMEN TRANSITORIO.pptxrorellanoq
 
Auditoría de Sistemas de Gestión
Auditoría    de   Sistemas     de GestiónAuditoría    de   Sistemas     de Gestión
Auditoría de Sistemas de GestiónYanet Caldas
 
Mecatronica Automotriz .pdf
Mecatronica Automotriz              .pdfMecatronica Automotriz              .pdf
Mecatronica Automotriz .pdfleonardocahua1
 

Último (20)

Trabajo practico N°14 - Despacho Economico de Cargas - Campus 2022.pdf
Trabajo practico N°14 - Despacho Economico de Cargas - Campus 2022.pdfTrabajo practico N°14 - Despacho Economico de Cargas - Campus 2022.pdf
Trabajo practico N°14 - Despacho Economico de Cargas - Campus 2022.pdf
 
Video sustentación GA2- 240201528-AA3-EV01.pptx
Video sustentación GA2- 240201528-AA3-EV01.pptxVideo sustentación GA2- 240201528-AA3-EV01.pptx
Video sustentación GA2- 240201528-AA3-EV01.pptx
 
3er Informe Laboratorio Quimica General (2) (1).pdf
3er Informe Laboratorio Quimica General  (2) (1).pdf3er Informe Laboratorio Quimica General  (2) (1).pdf
3er Informe Laboratorio Quimica General (2) (1).pdf
 
Tema ilustrado 9.2.docxbbbbbbbbbbbbbbbbbbb
Tema ilustrado 9.2.docxbbbbbbbbbbbbbbbbbbbTema ilustrado 9.2.docxbbbbbbbbbbbbbbbbbbb
Tema ilustrado 9.2.docxbbbbbbbbbbbbbbbbbbb
 
INFORME de pregrado ingenieria de vias.pdf
INFORME de pregrado ingenieria de vias.pdfINFORME de pregrado ingenieria de vias.pdf
INFORME de pregrado ingenieria de vias.pdf
 
dokumen.tips_311-determinacion-del-espacio-estatico.pptx
dokumen.tips_311-determinacion-del-espacio-estatico.pptxdokumen.tips_311-determinacion-del-espacio-estatico.pptx
dokumen.tips_311-determinacion-del-espacio-estatico.pptx
 
TECNOLOGIA DE CONCRETO 2024 estudiante.pdf
TECNOLOGIA DE CONCRETO 2024 estudiante.pdfTECNOLOGIA DE CONCRETO 2024 estudiante.pdf
TECNOLOGIA DE CONCRETO 2024 estudiante.pdf
 
G4 - CASO DE ESTUDIO - VOLUMEN DE UN RESERVORIO (1).pptx
G4 - CASO DE ESTUDIO - VOLUMEN DE UN RESERVORIO (1).pptxG4 - CASO DE ESTUDIO - VOLUMEN DE UN RESERVORIO (1).pptx
G4 - CASO DE ESTUDIO - VOLUMEN DE UN RESERVORIO (1).pptx
 
Mantenimiento-de-Transformadores-Monofasicos[1].pptx
Mantenimiento-de-Transformadores-Monofasicos[1].pptxMantenimiento-de-Transformadores-Monofasicos[1].pptx
Mantenimiento-de-Transformadores-Monofasicos[1].pptx
 
Tippens fisica 7eDIAPOSITIVAS TIPENS Tippens_fisica_7e_diapositivas_33.ppt
Tippens fisica 7eDIAPOSITIVAS TIPENS Tippens_fisica_7e_diapositivas_33.pptTippens fisica 7eDIAPOSITIVAS TIPENS Tippens_fisica_7e_diapositivas_33.ppt
Tippens fisica 7eDIAPOSITIVAS TIPENS Tippens_fisica_7e_diapositivas_33.ppt
 
Arquitecto cambio de uso de suelo Limache
Arquitecto cambio de uso de suelo LimacheArquitecto cambio de uso de suelo Limache
Arquitecto cambio de uso de suelo Limache
 
ATS-FORMATOa.pdf PARA MANTENIMIENTO MECANICO
ATS-FORMATOa.pdf PARA MANTENIMIENTO MECANICOATS-FORMATOa.pdf PARA MANTENIMIENTO MECANICO
ATS-FORMATOa.pdf PARA MANTENIMIENTO MECANICO
 
27311861-Cuencas-sedimentarias-en-Colombia.ppt
27311861-Cuencas-sedimentarias-en-Colombia.ppt27311861-Cuencas-sedimentarias-en-Colombia.ppt
27311861-Cuencas-sedimentarias-en-Colombia.ppt
 
ingenieria grafica para la carrera de ingeniera .pptx
ingenieria grafica para la carrera de ingeniera .pptxingenieria grafica para la carrera de ingeniera .pptx
ingenieria grafica para la carrera de ingeniera .pptx
 
422382393-Curso-de-Tableros-Electricos.pptx
422382393-Curso-de-Tableros-Electricos.pptx422382393-Curso-de-Tableros-Electricos.pptx
422382393-Curso-de-Tableros-Electricos.pptx
 
INTEGRATED PROJECT DELIVERY.pdf (ENTREGA INTEGRADA DE PROYECTOS)
INTEGRATED PROJECT DELIVERY.pdf (ENTREGA INTEGRADA DE PROYECTOS)INTEGRATED PROJECT DELIVERY.pdf (ENTREGA INTEGRADA DE PROYECTOS)
INTEGRATED PROJECT DELIVERY.pdf (ENTREGA INTEGRADA DE PROYECTOS)
 
entropia y neguentropia en la teoria general de sistemas
entropia y neguentropia en la teoria general de sistemasentropia y neguentropia en la teoria general de sistemas
entropia y neguentropia en la teoria general de sistemas
 
8 2024A CONDUCCION DE CALOR EN REGIMEN TRANSITORIO.pptx
8 2024A CONDUCCION DE CALOR EN REGIMEN TRANSITORIO.pptx8 2024A CONDUCCION DE CALOR EN REGIMEN TRANSITORIO.pptx
8 2024A CONDUCCION DE CALOR EN REGIMEN TRANSITORIO.pptx
 
Auditoría de Sistemas de Gestión
Auditoría    de   Sistemas     de GestiónAuditoría    de   Sistemas     de Gestión
Auditoría de Sistemas de Gestión
 
Mecatronica Automotriz .pdf
Mecatronica Automotriz              .pdfMecatronica Automotriz              .pdf
Mecatronica Automotriz .pdf
 

Destacado

Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Applitools
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at WorkGetSmarter
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...DevGAMM Conference
 
Barbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationErica Santiago
 
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellGood Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellSaba Software
 

Destacado (20)

Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
 
ChatGPT webinar slides
ChatGPT webinar slidesChatGPT webinar slides
ChatGPT webinar slides
 
More than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike RoutesMore than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike Routes
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
 
Barbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy Presentation
 
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellGood Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
 

Semana 14 PDI nuevo - procesamiento digital de imagenes.pdf

  • 1. UNIVERSIDAD NACIONAL PEDRO RUIZ GALLO PROCESAMIENTO DIGITAL DE IMÁGENES Mg. Ing. Oscar Ucchelly Romero Cortez Curso: Docente: FACULTAD DE CIENCIAS FÍSICAS Y MATEMÁTICAS Semestre 2022 – I
  • 2. Procesamiento Digital de Imágenes VECINDAD Para determinar si dos pixeles son vecinos o no (adyacentes). Vecindad 4: Se considera pixeles conectados en direcciones perpendiculares (arriba, abajo, derecha, izquierda). Vecindad 8: Se considera también los pixeles vecinos diagonales.
  • 4. Procesamiento Digital de Imágenes CONECTIVIDAD Dos pixeles están con la misma etiqueta están conectados si existe un camino del uno al otro a través de pixeles vecinos con la misma etiqueta. La conectividad puede ser: Vecindad 4: Se toma en cuenta la vecindad 4 para determinar la conectividad de pixeles. Vecindad 8: Se toma en cuenta la vecindad 8 para determinar la conectividad de pixeles.
  • 5. Procesamiento Digital de Imágenes CONECTIVIDAD Etiquetado: Agrupación de pixeles con características similares. Si se elige conectividad conexión 4 se consideraría como dos objetos diferentes, pero si se elige conectividad conexión 8 se consideraría como un solo objeto (vecindad diagonal).
  • 6. Procesamiento Digital de Imágenes CONECTIVIDAD Etiquetado: Agrupación de pixeles con características similares. Si se elige conectividad conexión 4 se consideraría como dos objetos diferentes, pero si se elige conectividad conexión 8 se consideraría como un solo objeto (vecindad diagonal).
  • 7. Procesamiento Digital de Imágenes CUENTA Y ETIQUETADO DE OBJETOS EN UNA IMAGEN Para contar la cantidad de objetos presentes en una imagen se realiza el procedimiento: - Leer la imagen. - Convertirla a escala de grises y luego binarizarla. - En la imagen binarizada se requiere que los objetos a contar estén en blanco (255) y con fondo negro (0), si no fuera el caso entonces aplicar el comando: IB = not (I)
  • 8. Procesamiento Digital de Imágenes CUENTA Y ETIQUETADO DE OBJETOS EN UNA IMAGEN Para contar la cantidad de objetos presentes en una imagen se realiza el procedimiento: - Ejecutar el siguiente comando para etiquetar los objetos. Cada objeto encontrado se etiqueta con un número entero: 1,2,3,…. IB_label = bwlabel(IB , C) Donde: C = 4 ó 8 (conexión) - Para obtener el número de objetos: n = max(max(IB_label))
  • 9. Procesamiento Digital de Imágenes EJEMPLO ¿Contabilizar el número de objetos de la siguiente imagen?
  • 10. Procesamiento Digital de Imágenes SOLUCIÓN
  • 12. Procesamiento Digital de Imágenes EJEMPLO Para seleccionar el objeto seleccionado y se aisla en la matriz “IB_sele”
  • 14. Procesamiento Digital de Imágenes EJERCICIOS
  • 15. Procesamiento Digital de Imágenes EJERCICIOS