code: def make_data(
      format="numpy",
      means=[[3, 2], [7, 7], [0, 8]],
      covs=[
          [[5, -1.5], [-1.5, 1]],
          [[1, 0.5], [0.5, 4]],
          [[5, 1], [1, 5]],
      ],
      sizes=[100, 50, 50],
      avg_trace=0.8,
      seed=SEED,  # set to None for non-reproducible randomness
  ):
      """format specifies what X (and y) looks like, one of:
      'numpy', 'sparse', 'dataframe', or 'series'.
      """
      np.random.seed(seed=seed)
  
      K = len(means)  # number of classes
      data = []
      labels = []
      test_data = []
      test_labels = []
  
      for idx in range(K):
          data.append(
              np.random.multivariate_normal(
                  mean=means[idx], cov=covs[idx], size=sizes[idx]
              )
          )
          test_data.append(
              np.random.multivariate_normal(
                  mean=means[idx], cov=covs[idx], size=sizes[idx]
              )
          )
          labels.append(np.array([idx for i in range(sizes[idx])]))
          test_labels.append(np.array([idx for i in range(sizes[idx])]))
      X_train = np.vstack(data)
      true_labels_train = np.hstack(labels)
      X_test = np.vstack(test_data)
      true_labels_test = np.hstack(test_labels)
  
      if format == "sparse":
          X_train = scipy.sparse.csr_matrix(X_train)
          X_test = scipy.sparse.csr_matrix(X_test)
      elif format == "dataframe":
          X_train = pd.DataFrame(X_train)
          X_test = pd.DataFrame(X_test)
          # true_labels_train = list(true_labels_train)
          # true_labels_test = list(true_labels_test)
      elif format == "series":
          X_train = pd.Series(X_train[:, 0])
          X_test = pd.Series(X_test[:, 0])
          # true_labels_train = pd.Series(true_labels_train)
          # true_labels_test = pd.Series(true_labels_test)
      elif format != "numpy":
          raise ValueError("invalid value specified for: `format`.")
  
      # Compute p(true_label=k)
      py = np.bincount(true_labels_train) / float(
          len(true_labels_train)
      )
  
      noise_matrix = generate_noise_matrix_from_trace(
          K,
          trace=avg_trace * K,
          py=py,
          valid_noise_matrix=True,
          seed=seed,
      )
  
      # Generate our noisy labels using the noise_matrix.
      s = generate_noisy_labels(true_labels_train, noise_matrix)
      ps = np.bincount(s) / float(len(s))
  
      return {
          "X_train": X_train,
          "true_labels_train": true_labels_train,
          "X_test": X_test,
          "true_labels_test": true_labels_test,
          "labels": s,
          "ps": ps,
          "py": py,
          "noise_matrix": noise_matrix,
      }
  
imports: from copy import deepcopy
  import warnings
  from sklearn.linear_model import LogisticRegression
  from sklearn.base import BaseEstimator
  from sklearn.model_selection import GridSearchCV
  import scipy
  import pytest
  import numpy
  import pandas
  from cleanlab.classification import CleanLearning
  from cleanlab.benchmarking.noise_generation import generate_noise_matrix_from_trace
  from cleanlab.benchmarking.noise_generation import generate_noisy_labels
  from cleanlab.internal.latent_algebra import compute_inv_noise_matrix
  from cleanlab.count import compute_confident_joint, estimate_cv_predicted_probabilities, get_confident_thresholds
  from cleanlab.filter import find_label_issues
label_desc: Use image node_id 1 for calling a global function with example usage: make_data(format, means, covs, sizes, avg_trace, seed) and returns: dict