def __init__(self, data, initial_centers, tolerance=<NUM_LIT>, ccore=True, **kwargs):
self.__pointer_data = numpy.array(data)<EOL>self.__clusters = []<EOL>self.__centers = numpy.array(initial_centers)<EOL>self.__tolerance = tolerance<EOL>self.__total_wce = <NUM_LIT:0><EOL>self.__observer = kwargs.get('<STR_LIT>', None)<EOL>self.__metric = kwargs.get('<STR_LIT>', distance_metric(type_metric.EUCLIDEAN_SQUARE))<EOL>self.__itermax = kwargs.get('<STR_LIT>', <NUM_LIT:100>)<EOL>if self.__metric.get_type() != type_metric.USER_DEFINED:<EOL><INDENT>self.__metric.enable_numpy_usage()<EOL><DEDENT>else:<EOL><INDENT>self.__metric.disable_numpy_usage()<EOL><DEDENT>self.__ccore = ccore and self.__metric.get_type() != type_metric.USER_DEFINED<EOL>if self.__ccore is True:<EOL><INDENT>self.__ccore = ccore_library.workable()<EOL><DEDENT>
!
        @brief Constructor of clustering algorithm K-Means.
        @details Center initializer can be used for creating initial centers, for example, K-Means++ method.

        @param[in] data (array_like): Input data that is presented as array of points (objects), each point should be represented by array_like data structure.
        @param[in] initial_centers (array_like): Initial coordinates of centers of clusters that are represented by array_like data structure: [center1, center2, ...].
        @param[in] tolerance (double): Stop condition: if maximum value of change of centers of clusters is less than tolerance then algorithm stops processing.
        @param[in] ccore (bool): Defines should be CCORE library (C++ pyclustering library) used instead of Python code or not.
        @param[in] **kwargs: Arbitrary keyword arguments (available arguments: 'observer', 'metric', 'itermax').

        <b>Keyword Args:</b><br>
            - observer (kmeans_observer): Observer of the algorithm to collect information about clustering process on each iteration.
            - metric (distance_metric): Metric that is used for distance calculation between two points (by default euclidean square distance).
            - itermax (uint): Maximum number of iterations that is used for clustering process (by default: 200).

        @see center_initializer