code: def _FindAttrInOpDef(attr_name, op_def):
      for attr_def in op_def.attr:
          if attr_name == attr_def.name:
              return attr_def
      return None
  
imports: import contextlib
  from tensorflow.core.framework import graph_pb2
  from tensorflow.python import tf2
  from tensorflow.python.client import pywrap_tf_session
  from tensorflow.python.framework import c_api_util
  from tensorflow.python.framework import device
  from tensorflow.python.framework import errors
  from tensorflow.python.framework import function
  from tensorflow.python.framework import op_def_registry
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import tensor
  from tensorflow.python.ops import control_flow_util
  from tensorflow.python.util import compat
  from tensorflow.python.util.deprecation import deprecated_args
  from tensorflow.python.util.tf_export import tf_export
label_desc: Use image node_id 7 for calling a global function with example usage: _FindAttrInOpDef(attr_name, op_def) and returns: None, attr_def