code: def get_filename(file):
      
      if not os.path.exists(file):
          return None
      return "%s%s" % os.path.splitext(file)
docs: Safe method to retrieve only the name of the file.
      :param file: Path of the file to retrieve the name from.
      :return: None if the file is non-existant, otherwise the filename (extension included)
      :rtype: None, str