code: def plot_adjacency_matrix(
      adjacency_matrix: pd.DataFrame,
      is_directed: bool,
      filename: Optional[str] = None,
      display_plot: bool = True,
  ) -> None:
      plot(
          nx.from_pandas_adjacency(
              adjacency_matrix,
              nx.DiGraph() if is_directed else nx.Graph(),
          ),
          display_plot=display_plot,
          filename=filename,
      )
  
file_path: dowhy/dowhy/utils/plotting.py
imports: import logging
  import os
  import tempfile
  from typing import Any, Dict, List, Optional, Tuple, Union
  import matplotlib.pyplot
  import networkx
  import numpy
  import pandas
  from matplotlib import image
label_desc: Use image node_id 2 for calling a global function with example usage: plot_adjacency_matrix(adjacency_matrix, is_directed, filename, display_plot) without return types