I am trying to do image processing with Python. What I actually want to do is I have image with human and I need to indetify human faces or detect circle (basically human face). what I have done so far us
I have done edge detection for image using sobel edge detection.
Then I have converted image into binary image which saves binary image ad prints out array of the image which is 0 or 255 (Black and White)
Now what I'm confused about after this what can I do to detect circle in image and print out how many human present in image.
I am using still images so I am giving the input for the image
I am using Python, PIL, NumPy, and SciPy. I do not want to use OpenCV. I want to detect human face and count how many people are in image and then print out the number of people in image.
import numpy
import scipy
from scipy import ndimage
im = scipy.misc.imread('test5.jpg')
im = im.astype('int32')
dx = ndimage.sobel(im, 0) # horizontal derivative
dy = ndimage.sobel(im, 1) # vertical derivative
mag = numpy.hypot(dx, dy) # magnitude
mag *= 255.0 / numpy.max(mag) # normalize (Q&D)
scipy.misc.imsave('sobel.jpg', mag)
The code above its not mine I got it from online.
I have also asked this question in other forum as well.HERE