added centroid generator script