Substituted the type of the centroids, now they are Instances