code: def largest_first(binary_observables, adj):
      """Performs graph-colouring using the Largest Degree First heuristic. Runtime is quadratic in
      number of vertices.
  
      Args:
          binary_observables (array[int]): the set of Pauli words represented by a column matrix
              of the Pauli words in binary vector represenation
          adj (array[int]): the adjacency matrix of the Pauli graph
  
      Returns:
          dict(int, list[array[int]]): keys correspond to colours (labelled by integers) and values
          are lists of Pauli words of the same colour in binary vector representation.
  
      **Example**
  
      >>> binary_observables = np.array([[1., 1., 0.],
      ... [1., 0., 0.],
      ... [0., 0., 1.],
      ... [1., 0., 1.]])
      >>> adj = np.array([[0., 0., 1.],
      ... [0., 0., 1.],
      ... [1., 1., 0.]])
      >>> largest_first(binary_observables, adj)
      {1: [array([0., 0., 1.])], 2: [array([1., 0., 0.]), array([1., 1., 0.])]}
      """
  
      n_terms = np.shape(adj)[0]
      terms = [binary_observables[i] for i in range(n_terms)]
      rows = adj.sum(axis=0)
      ind = np.argsort(rows)[::-1]
      m_array = adj[ind, :][:, ind]
      colours = {}
      c_vec = np.zeros(n_terms, dtype=int)
      k = 0
      for i in range(n_terms):
          neighbours = np.argwhere(m_array[i, :])
          colours_available = set(np.arange(1, k + 1)) - set(
              c_vec[[x[0] for x in neighbours]]
          )
          term = terms[ind[i]]
          if not colours_available:
              k += 1
              c_vec[i] = k
              colours[c_vec[i]] = [term]
          else:
              c_vec[i] = min(list(colours_available))
              colours[c_vec[i]].append(term)
      return colours
  
label_desc: Use image node_id 1 for calling a global function with example usage: largest_first(binary_observables, adj) and returns: colours