Cython implementation of the points in polygon algorithm