code: def _FileNameToKey(filename):
      """From a given filename, construct a key we use for api objects."""
  
      def _ReplaceDashWithCaps(matchobj):
          match = matchobj.group(0)
          return match[1].upper()
  
      base_filename = os.path.basename(filename)
      base_filename_without_ext = os.path.splitext(base_filename)[0]
      api_object_key = re.sub(
          "((-[a-z]){1})",
          _ReplaceDashWithCaps,
          base_filename_without_ext,
      )
      return api_object_key
  
imports: import argparse
  import os
  import re
  import sys
  import tensorflow
  from google.protobuf import message
  from google.protobuf import text_format
  from tensorflow.python.lib.io import file_io
  from tensorflow.python.platform import resource_loader
  from tensorflow.python.platform import test
  from tensorflow.python.platform import tf_logging
  from tensorflow.tools.api.lib import api_objects_pb2
  from tensorflow.tools.api.lib import python_object_to_proto_visitor
  from tensorflow.tools.common import public_api
  from tensorflow.tools.common import traverse
label_desc: Use image node_id 3 for calling a global function with example usage: _FileNameToKey(filename) and returns: api_object_key, match