class_docstr: !
  @brief Provides services for preparing initial means and covariances for Expectation-Maximization algorithm.
  @details Initialization strategy is defined by enumerator 'ema_init_type': random initialization and 
            kmeans with kmeans++ initialization. Here an example of initialization using kmeans strategy:
  
  @code
      from pyclustering.utils import read_sample
      from pyclustering.samples.definitions import FAMOUS_SAMPLES
      from pyclustering.cluster.ema import ema_initializer
  
      sample = read_sample(FAMOUS_SAMPLES.SAMPLE_OLD_FAITHFUL)
      amount_clusters = 2
  
      initial_means, initial_covariance = ema_initializer(sample, amount_clusters).initialize()
      print(initial_means)
      print(initial_covariance)
  @endcode
code: def __initialize_kmeans(self):
      initial_centers = kmeans_plusplus_initializer(
          self.__sample, self.__amount
      ).initialize()
      kmeans_instance = kmeans(
          self.__sample, initial_centers, ccore=True
      )
      kmeans_instance.process()
  
      means = kmeans_instance.get_centers()
  
      covariances = []
      initial_clusters = kmeans_instance.get_clusters()
      for initial_cluster in initial_clusters:
          if len(initial_cluster) > 1:
              cluster_sample = [
                  self.__sample[index_point]
                  for index_point in initial_cluster
              ]
              covariances.append(
                  numpy.cov(cluster_sample, rowvar=False)
              )
          else:
              dimension = len(self.__sample[0])
              covariances.append(
                  numpy.zeros((dimension, dimension))
                  + random.random() / 10.0
              )
  
      return means, covariances
  
imports: import numpy
  import random
  from pyclustering.cluster import cluster_visualizer
  from pyclustering.cluster.center_initializer import kmeans_plusplus_initializer
  from pyclustering.cluster.kmeans import kmeans
  from pyclustering.utils import pi, calculate_ellipse_description, euclidean_distance_square
  from enum import IntEnum
  import matplotlib.pyplot
  import matplotlib.animation
  from matplotlib import patches
label_desc: Use image node_id 6 for calling the ema_initializer obj's underlying member method code with example usage: obj.__initialize_kmeans() and returns: means,  covariances