code: def plot_outliers(
      embedding: Union[np.ndarray, pd.DataFrame],
      classifiers: dict,
      name: str,
      xy_extent=((0, 10), (0, 10)),
      figsize=(7, 4),
      xy=(1, 1),
      xytext=(2, 2),
      border=1,
  ):
      """
      Plot the decision function for several outliers detection algorithms.
          Although embedding can be any size, it is expected to be 2D umap coordinates
  
      Args:
          embedding (np.ndarray): embedding of the data
          classifiers (dict): dict of classifiers to use, with keys as names and values as sklearn classifiers
          name (str): name of the dataset
          xy_extent (tuple): extent of the plot
          figsize (tuple): size of the plot
          xy (tuple): xy position of the legend
          xytext (tuple): xy position of the legend text
          border (int): border around the plot
      returns:
          fig (matplotlib.figure.Figure): figure of the plot and axes
      """
      colors = ["m", "r", "b", "g"]
      legend1 = {}
      if xy_extent is None:
          mminx, mmaxx = embedding.T[0].min(), embedding.T[0].max()
          mminy, mmaxy = embedding.T[1].min(), embedding.T[1].max()
      else:
          mminx, mmaxx = xy_extent[0]
          mminy, mmaxy = xy_extent[1]
  
      deltax = mmaxx - mminx
      deltay = mmaxy - mminy
  
      logger.info(
          f"min extent x: {mminx}, max extent x: {mmaxx}, delta: {deltax}"
      )
      logger.info(
          f"min extent y: {mminy}, max extent y: {mmaxy}, delta: {deltay}"
      )
  
      # Learn a frontier for outlier detection with several classifiers
      xx, yy = np.meshgrid(
          np.linspace(mminx - border, mmaxx + border, 500),
          np.linspace(mminy - border, mmaxy + border, 500),
      )
      fig = plt.figure(1, figsize=figsize)
      ax = plt.subplot()
      for i, (clf_name, clf) in enumerate(classifiers.items()):
          plt.figure(1, figsize=figsize)
          Z1 = clf.decision_function(np.c_[xx.ravel(), yy.ravel()])
          Z1 = Z1.reshape(xx.shape)
          legend1[clf_name] = plt.contour(
              xx, yy, Z1, levels=[0], linewidths=2, colors=colors[i]
          )
  
      legend1_values_list = list(legend1.values())
      legend1_keys_list = list(legend1.keys())
  
      # Plot the results (= shape of the data points cloud)
      plt.figure(1, figsize=figsize)  # two clusters
      plt.title(f"Outlier detection: {name}")
      plt.scatter(embedding[:, 0], embedding[:, 1], color="black", s=22, alpha=0.75)  # type: ignore
      bbox_args = dict(boxstyle="round", fc="0.8")
      arrow_args = dict(arrowstyle="->")
      plt.annotate(
          "outlying points",
          xy=xy,
          xycoords="data",
          textcoords="data",
          xytext=xytext,
          bbox=bbox_args,
          arrowprops=arrow_args,
      )
      plt.xlim((xx.min(), xx.max()))
      plt.ylim((yy.min(), yy.max()))
      plt.legend(
          (
              legend1_values_list[0].collections[0],
              legend1_values_list[1].collections[0],
              legend1_values_list[2].collections[0],
              legend1_values_list[3].collections[0],
          ),
          (
              legend1_keys_list[0],
              legend1_keys_list[1],
              legend1_keys_list[2],
              legend1_keys_list[3],
          ),
          loc="upper center",
          prop=matplotlib.font_manager.FontProperties(size=11),
      )
      plt.ylabel("y UMAP")
      plt.xlabel("x UMAP")
  
      plt.show()
  
      return fig, ax
  
imports: from typing import Union, Tuple
  import pandas
  import logging
label_desc: Use image node_id 3 for calling a global function with example usage: plot_outliers(embedding, classifiers, name, xy_extent, figsize, xy, xytext, border) and returns: fig,  ax