code: def _remove_zipmap(node_list):
      """
      Method used to remove ZipMap operators in the graph.
  
      """
      output_node_list = []
  
      for node_ in _topological_sort(node_list):
          if node_.op_type == "ZipMap":
              # We remove this map operator and just use an array.
              assert len(node_.input) == len(node_.output)
              # Check if in single path to output
              assert (
                  len(node_.successor) == 1
                  and node_.successor[0].in_or_out
                  and len(node_.precedence) == 1
                  and not node_.precedence[0].in_or_out
              )
  
              # We override the output names of the operator preceeding ZipMap with the output names of the ZipMap.
              # This will evenutally create problems if the output_names of the predecessor
              # are used somewhere else, but for the moment it works.
              # Perhaps a better strategy is to add an identity node.
              input_keys = list(node_.input.keys())
              for i in range(len(input_keys)):
                  node_.precedence[0].output.pop(input_keys[i])
                  node_.precedence[0].output[
                      node_.origin.output[i]
                  ] = node_.origin.output[i]
              node_.precedence[0].origin.output[
                  :
              ] = node_.output.values()
          else:
              output_node_list.append(node_)
  
      return output_node_list
  
imports: from collections import OrderedDict
  from copy import deepcopy
  import pprint
  from uuid import uuid4
  import numpy
  from onnxconverter_common.optimizer import LinkedNode, _topological_sort
  from sklearn import pipeline
  from sklearn.compose import ColumnTransformer
  from sklearn.ensemble import BaggingClassifier, BaggingRegressor
  from sklearn.model_selection import GridSearchCV, RandomizedSearchCV
  from sklearn.multioutput import MultiOutputRegressor, RegressorChain
  from sklearn.preprocessing import OneHotEncoder
  from .containers import CommonSklearnModelContainer, CommonONNXModelContainer, CommonSparkMLModelContainer
  from ._topology import Topology
  from ._utils import sklearn_installed, sparkml_installed
  from .operator_converters import constants
  from .supported import get_sklearn_api_operator_name, get_onnxml_api_operator_name, get_sparkml_api_operator_name
label_desc: Use image node_id 23 for calling a global function with example usage: _remove_zipmap(node_list) and returns: output_node_list