# Topology Approach to Cell Counting. Goals Algorithm detects and captures objects in an image This algorithm computes objects – Locations – Measurement.

## Presentation on theme: "Topology Approach to Cell Counting. Goals Algorithm detects and captures objects in an image This algorithm computes objects – Locations – Measurement."— Presentation transcript:

Topology Approach to Cell Counting

Goals Algorithm detects and captures objects in an image This algorithm computes objects – Locations – Measurement – Identify set of pixels for extraction from the image

What is an Object? What is an object? – Binary image Connected cluster of black pixels on a white background Connected cluster of white pixels on a black background

What is an Object? What is an object? – Gray Scale image Connected cluster of dark pixels on a light background Connected cluster of light pixels on a dark background

What is an Object? What is an object? – Color image Connected cluster of dark color pixels on a light color background Connected cluster of light color pixels on a dark color background

Gray Scale Images Gray Scale images – For a threshold A binary image is created – For each level of gray chosen as threshold Collection (255) of binary images are created – As threshold grows Objects grows and merge Dark pixels form dark objects for each threshold Light pixels form light objects for each threshold Light objects may turn out holes in dark objects or vice versa.

Gray Scale Image 12345678910111213141516 1 7777777777777777 2 7666666666666667 3 7655555555555567 4 7654444444444567 5 7654333333334567 6 7654322222234567 7 7654321111234567 8 7654321001234567 9 7654321001234567 10 7654321111234567 11 7654322222234567 12 7654333333334567 13 7654444444444567 14 7655555555555567 15 7666666666666667 16 7777777777777777 Image size (WxH) = 16x16 pixels 8 Levels of gray Black = 0 White = 7

Gray Scale Image Visual 12345678910111213141516 1 7777777777777777 2 7666666666666667 3 7655555555555567 4 7654444444444567 5 7654333333334567 6 7654322222234567 7 7654321111234567 8 7654321001234567 9 7654321001234567 10 7654321111234567 11 7654322222234567 12 7654333333334567 13 7654444444444567 14 7655555555555567 15 7666666666666667 16 7777777777777777 Image size (WxH) = 16x16 pixels 8 Levels of gray Black = 0 White = 7

Binary Image 12345678910111213141516 1 1111111111111111 2 1111111111111111 3 1111111111111111 4 1111111111111111 5 1111111111111111 6 1111111111111111 7 1111111111111111 8 1111111001111111 9 1111111001111111 10 1111111111111111 11 1111111111111111 12 1111111111111111 13 1111111111111111 14 1111111111111111 15 1111111111111111 16 1111111111111111 Image size (WxH) = 16x16 pixels Threshold = 0 Level Set: If P(i,j) <= 0 B(i,j) = 0 (Black) Else B(i,j) = 1 (White)

Binary Image 12345678910111213141516 1 1111111111111111 2 1111111111111111 3 1111111111111111 4 1111111111111111 5 1111111111111111 6 1111111111111111 7 1111110000111111 8 1111110000111111 9 1111110000111111 10 1111110000111111 11 1111111111111111 12 1111111111111111 13 1111111111111111 14 1111111111111111 15 1111111111111111 16 1111111111111111 Image size (WxH) = 16x16 pixels Threshold = 1 Level Set: If P(i,j) <= 1 B(i,j) = 0 (Black) Else B(i,j) = 1 (White)

Binary Image 12345678910111213141516 1 1111111111111111 2 1111111111111111 3 1111111111111111 4 1111111111111111 5 1111111111111111 6 1111100000011111 7 1111100000011111 8 1111100000011111 9 1111100000011111 10 1111100000011111 11 1111100000011111 12 1111111111111111 13 1111111111111111 14 1111111111111111 15 1111111111111111 16 1111111111111111 Image size (WxH) = 16x16 pixels Threshold = 2 Level Set: If P(i,j) <= 2 B(i,j) = 0 (Black) Else B(i,j) = 1 (White)

Binary Image 12345678910111213141516 1 1111111111111111 2 1111111111111111 3 1111111111111111 4 1111111111111111 5 1111000000001111 6 1111000000001111 7 1111000000001111 8 1111000000001111 9 1111000000001111 10 1111000000001111 11 1111000000001111 12 1111000000001111 13 1111111111111111 14 1111111111111111 15 1111111111111111 16 1111111111111111 Image size (WxH) = 16x16 pixels Threshold = 3 Level Set: If P(i,j) <= 3 B(i,j) = 0 (Black) Else B(i,j) = 1 (White)

Binary Image 12345678910111213141516 1 1111111111111111 2 1111111111111111 3 1111111111111111 4 1110000000000111 5 1110000000000111 6 1110000000000111 7 1110000000000111 8 1110000000000111 9 1110000000000111 10 1110000000000111 11 1110000000000111 12 1110000000000111 13 1110000000000111 14 1111111111111111 15 1111111111111111 16 1111111111111111 Image size (WxH) = 16x16 pixels Threshold = 4 Level Set: If P(i,j) <= 4 B(i,j) = 0 (Black) Else B(i,j) = 1 (White)

Binary Image 12345678910111213141516 1 1111111111111111 2 1111111111111111 3 1100000000000011 4 1100000000000011 5 1100000000000011 6 1100000000000011 7 1100000000000011 8 1100000000000011 9 1100000000000011 10 1100000000000011 11 1100000000000011 12 1100000000000011 13 1100000000000011 14 1100000000000011 15 1111111111111111 16 1111111111111111 Image size (WxH) = 16x16 pixels Threshold = 5 Level Set: If P(i,j) <= 5 B(i,j) = 0 (Black) Else B(i,j) = 1 (White)

Binary Image 12345678910111213141516 1 1111111111111111 2 1000000000000001 3 1000000000000001 4 1000000000000001 5 1000000000000001 6 1000000000000001 7 1000000000000001 8 1000000000000001 9 1000000000000001 10 1000000000000001 11 1000000000000001 12 1000000000000001 13 1000000000000001 14 1000000000000001 15 1000000000000001 16 1111111111111111 Image size (WxH) = 16x16 pixels Threshold = 6 Level Set: If P(i,j) <= 6 B(i,j) = 0 (Black) Else B(i,j) = 1 (White)

Binary Image 12345678910111213141516 1 0000000000000000 2 0000000000000000 3 0000000000000000 4 0000000000000000 5 0000000000000000 6 0000000000000000 7 0000000000000000 8 0000000000000000 9 0000000000000000 10 0000000000000000 11 0000000000000000 12 0000000000000000 13 0000000000000000 14 0000000000000000 15 0000000000000000 16 0000000000000000 Image size (WxH) = 16x16 pixels Threshold = 7 Level Set: If P(i,j) <= 7 B(i,j) = 0 (Black) Else B(i,j) = 1 (White)

Characteristics of Objects Size = area in pixels Contrast Compactness – Perimeter/(4*Pi*Area) Saliency

Loss less Processing Nothing is removed or ignored No iteration, approximation No floating point arithmetic

Application The algorithm will work on the following types of images – That contains certain objects – Blood cells, finger prints, logos, mug shots – Machine vision for industrial inspection It will not work on the following images – Images that are light on one side and dark on the other side

Homology Classes: Betti Numbers B1: Number of objects in an image B2: Number of holes in an object B3: Number of voids or cavities B 0 (parts)B 1 (holes)B 2 (voids) Letter O110 Two letters O 220 Letter B120 Donut110 Tire121 Ball101 The tire (torus) has two tunnels represented by these two "cycles". For the donut the blue one does not count because it can be contracted to a point. They are homologous! On the ball any "cycle" is like that.

Binary Images: Objective Identify Objects – Black objects on a white background – White objects on a black background Location Measurement Identify a set of pixels for extraction from the image Later migrate – From: binary to gray to color images – From: 2D to 3D images

Cell Decomposition Object is represented by – List of pair of numbers Pixel is square – Instead of a point Definitions – A vertex is a 0-cell – An edge is a 1-cell Boundaries consists of 2 end-points as 0-cells – A pixel is a 2-cell Boundaries consists of 4 edges as 1-cell – A voxel is a 3-cell Boundaries consists of 6 faces as 2-cells

Similar presentations