class_docstr: Class for generating a list of covariance matrices from time series.
  
  Prepare a TimeSeriesCovariance Object from time series in dictionary.
  
  Parameters
  ----------
  data_dict : dict
      Dictionary with 'time', 'raw_data', 'label' as key
      and the corresponding array as values.
  n_steps : int
      Size of the batches.
  n_timeseries : int
      The number of electrodes used for the recording.
  label_map : dictionary
      Encode the label into digits.
  margin : int
      Number of index to remove before and after a sign change (Can
      help getting a stationary signal).
  
  Attributes
  ----------
  label_map : dictionary
      Encode the label into digits.
  data_dict : dict
      Dictionary with 'time', 'raw_data', 'label' as key
      and the corresponding array as values.
  n_steps : int
      Size of the batches.
  n_timeseries : int
      The number of electrodes used for the recording.
  batches : array
      The start indexes of the batches to use to compute covariance matrices.
  margin : int
      Number of index to remove before and after a sign change (Can
      help getting a stationary signal).
  covs : array
      The covariance matrices.
  labels : array
      The digit labels corresponding to each batch.
  covec : array
      The vectorized version of the covariance matrices.
  diags : array
      The covariance matrices diagonals.
docstr: Transform the time series into batched covariance matrices.
  
  We also compute the corresponding vectors, variance vector,
  labels, and experiments.
docstr_tok: ["Transform","the","time","series","into","batched","covariance","matrices",".","We","also","compute","the","corresponding","vectors",",","variance","vector",",","labels",",","and","experiments","."]
code: def transform(self):
      """Transform the time series into batched covariance matrices.
  
      We also compute the corresponding vectors, variance vector,
      labels, and experiments.
      """
      if "y" not in self.data.keys():
          self._format_labels()
      self._create_batches()
      covs = []
      for i in self.batches:
          x = self.data["raw_data"][i : i + self.n_steps]
          covs.append(np.cov(x.transpose()))
      self.labels = gs.array(self.data["y"][self.batches])
      self.covs = gs.array(covs)
      self.covecs = gs.array(
          [
              SymmetricMatrices.basis_representation(cov)
              for cov in self.covs
          ]
      )
      self.diags = self.covs.diagonal(0, 1, 2)
  
imports: import numpy
  import geomstats.backend
  from geomstats.geometry.symmetric_matrices import SymmetricMatrices
label_desc: Use image node_id 4 for calling the TimeSeriesCovariance obj's underlying member method code with example usage: obj.transform() without return types