class_docstr: A dataset of random colored graphs.
  The task is to classify each graph with the color which occurs the most in
  its nodes.
  The graphs have `n_colors` colors, of at least `n_min` and at most `n_max`
  nodes connected with probability `p`.
class_docstr_tok: ["A","dataset","of","random","colored","graphs",".","The","task","is","to","classify","each","graph","with","the","color","which","occurs","the","most","in","its","nodes",".","The","graphs","have","`","n_colors","`","colors",",","of","at","least","`","n_min","`","and","at","most","`","n_max","`","nodes","connected","with","probability","`","p","`","."]
code: def read(self):
      def make_graph():
          n = np.random.randint(self.n_min, self.n_max)
          colors = np.random.randint(0, self.n_colors, size=n)
  
          # Node features
          x = np.zeros((n, self.n_colors))
          x[np.arange(n), colors] = 1
  
          # Edges
          a = np.random.rand(n, n) <= self.p
          a = np.maximum(a, a.T).astype(int)
          a = sp.csr_matrix(a)
  
          # Labels
          y = np.zeros((self.n_colors,))
          color_counts = x.sum(0)
          y[np.argmax(color_counts)] = 1
  
          return Graph(x=x, a=a, y=y)
  
      # We must return a list of Graph objects
      return [make_graph() for _ in range(self.n_samples)]
  
imports: import numpy
  import scipy.sparse
  import tensorflow
  from tensorflow.keras.layers import Dense
  from tensorflow.keras.losses import CategoricalCrossentropy
  from tensorflow.keras.metrics import categorical_accuracy
  from tensorflow.keras.models import Model
  from tensorflow.keras.optimizers import Adam
  from spektral.data import Dataset, DisjointLoader, Graph
  from spektral.layers import GCSConv, GlobalAvgPool
  from spektral.transforms.normalize_adj import NormalizeAdj
label_desc: Use image node_id 2 for calling the MyDataset obj's underlying member method code with example usage: obj.read() and returns: unknown, Graph