Ask Your Question

dalilamahirah's profile - activity

2020-10-23 10:01:33 -0600 received badge  Student (source)
2015-11-29 00:43:22 -0600 received badge  Enthusiast
2015-11-26 22:16:41 -0600 asked a question Count white pixels from bottom in binary image

I used python and openCV library. I would like to count white pixels from bottom of binary image. image description

This is my idea :-

for j in range(240, 0, -1):
      for i in range(140, 320, +1):
          if _____ :   #white pixels found at the bottom.Don't know what should I fill in that space.
                   count_white : cv2.countNonZero(img)   # is this command correct??
                   print count_white

Do I need 'for loop' to count pixels from bottom? How to count the pixels?

I really need your help. Thanks.

2015-11-20 08:11:48 -0600 commented question 'for loop' function for side fill binary image from bottom to top.

okay. if I do a watershed, how to write the 'for loop' coding which start from the bottom. I have no idea..

2015-11-20 04:09:38 -0600 commented question 'for loop' function for side fill binary image from bottom to top.

No. I'm referring to this link http://www.roborealm.com/tutorial/Obs... . I got the edge detection image but I don't know how to coding the side fill from bottom.

2015-11-20 02:55:50 -0600 received badge  Editor (source)
2015-11-20 02:47:38 -0600 asked a question 'for loop' function for side fill binary image from bottom to top.

How to write coding 'for loop' function to read pixels from bottom to top. Also how to do the side fill from bottom to the top of binary image after edge detection.

This is the image after edge detection : image description

I'm using python 2.7.3 and opencv 2.4.9

Refer to link text