code: def random_labels(num_samples, num_classes, multi_label=False):
      if multi_label:
          y = sparse.random(
              num_samples, num_classes, density=0.5, format="csr"
          )
          y.data[np.s_[:]] = 1
          y = y.astype(int)
      else:
          y = np.random.randint(0, high=num_classes, size=num_samples)
      return y
  
imports: import string
  import numpy
  from collections import Counter
  from scipy import sparse
  from sklearn.datasets import fetch_20newsgroups
  from small_text.data.datasets import SklearnDataset, TextDataset
  from small_text.data.sampling import _get_class_histogram
  from small_text.utils.labels import csr_to_list, list_to_csr
label_desc: Use image node_id 4 for calling a global function with example usage: random_labels(num_samples, num_classes, multi_label) and returns: y