code: def extract_paths_and_extensions(image_path):
      """
      Extract an image's file name, its extension, and its root path (the
      image's absolute path without the file name).
  
      :param image_path: The path to the image.
      :type image_path: String
      :return: A 3-tuple containing the image's file name, extension, and
       root path.
      """
      file_name, extension = os.path.splitext(image_path)
      root_path = os.path.dirname(image_path)
  
      return file_name, extension, root_path
  
imports: from __future__ import absolute_import, division, print_function, unicode_literals
  from builtins import *
  import os
  import glob
  import numbers
  import random
  import warnings
  import numpy
label_desc: Use image node_id 2 for calling a global function with example usage: extract_paths_and_extensions(image_path) and returns: file_name,  extension,  root_path