인공지능을 좋아하는 곧미남

이미지내에서 특정 객체만의 정보만 얻기 위한 segmentation 본문

Computer Vision .w Deeplearning/Segmentation

이미지내에서 특정 객체만의 정보만 얻기 위한 segmentation

곧미남 2022. 3. 15. 16:15

보통 이미지내에 존재하는 여러 객체들 중 내가 원하는 특정 객체의 정보만을 얻어 활용하고 싶은 경우가 있다. 예를들어, 특정 객체의 고유한 움직임이나, 변화에 관한 정보를 학습하기 위해서 객체의 영역만 분할하는 것이다. 하지만, 여러 분할 방법론이 있지만, 객체와 인접한 배경영역의 pixel value가 유사하거나, 조명에 의해서 객체 내부에 노이즈가 있다면, threshold를 명확히 잡는 것은 어려운 task이다.

 

오늘은 segmentation of computer vision method를 알아보겠습니다.

 

< INDEX >

1. Thresholding method for segmentation

 

2. Contextual method for segmentation

 

3. Clustering method for segmentation


우선 여러가지 방법론을 사용해봤지만, 내가 했던 Task에선 Clustering - Kmeans 방법이 제일 효과가 좋았다. rgb pixel value를 모두 고려하여 K개 만큼의 Label을 분할하고 각 Label별로 pixel value가 바운더리가 된다. 

 

내가 작성한 코드와 설명은 아래 주소에서 확인할 수 있다.

- github: https://github.com/sangheonEN/Die_Centering_Project/blob/main/video_task/video/video_binary_image_extraction/binary_segmentation.py -> cluster_k_means 메서드 참고

 

참고 문헌

https://www.cs.auckland.ac.nz/courses/compsci773s1c/lectures/ImageProcessing-html/topic3.htm

 

Image Segmentation

Segmentation partitions an image into distinct regions containing each pixels with similar attributes. To be meaningful and useful for image analysis and interpretation, the regions should strongly relate to depicted objects or features of interest. Meanin

www.cs.auckland.ac.nz

https://docs.opencv.org/4.x/d1/d5c/tutorial_py_kmeans_opencv.html

Comments