code: def plot_bashapes(
      self,
      graph,
      nodelist,
      y,
      node_idx,
      edgelist=None,
      title_sentence=None,
      figname=None,
  ):
      node_idxs = {
          k: int(v) for k, v in enumerate(y.reshape(-1).tolist())
      }
      node_color = ["#FFA500", "#4970C6", "#FE0000", "green"]
      colors = [
          node_color[v % len(node_color)] for k, v in node_idxs.items()
      ]
      self.plot_subgraph_with_nodes(
          graph,
          nodelist,
          node_idx,
          colors,
          edgelist=edgelist,
          figname=figname,
          title_sentence=title_sentence,
          subgraph_edge_color="black",
      )
  
imports: import tqdm
  import time
  import torch
  import numpy
  import torch.nn
  import networkx
  from math import sqrt
  from torch import Tensor
  from textwrap import wrap
  from torch.optim import Adam
  import matplotlib.pyplot
  import torch.nn.functional
  from torch_geometric.data import Data
  from torch_geometric.nn.conv import MessagePassing
  from torch_geometric.utils import to_networkx
  from torch_geometric.utils.num_nodes import maybe_num_nodes
  from typing import Tuple, List, Dict, Optional
  from .shapley import gnn_score, GnnNetsNC2valueFunc, GnnNetsGC2valueFunc, sparsity
  from torch_geometric.datasets import MoleculeNet
  from rdkit import Chem
label_desc: Use image node_id 7 for calling the PlotUtils obj's underlying member method code with example usage: obj.plot_bashapes(graph, nodelist, y, node_idx, edgelist, title_sentence, figname) without return types