code: def generic_filename(path):
      '''
      Extract filename of given path os-indepently, taking care of known path
      separators.
  
      :param path: path
      :return: filename
      :rtype: str or unicode (depending on given path)
      '''
  
      for sep in common_path_separators:
          if sep in path:
              _, path = path.rsplit(sep, 1)
      return patf generic_filename(path):
      '''
      Extract filename of given path os-indepently, taking care of known path
      separators.
  
      :param path: path
      :return: filename
      :rtype: str or unicode (depending on given path)
      '''
  
      for sep in common_path_separators:
          if sep in path:
              _, path = path.rsplit(sep, 1)
      return path
docs: Extract filename of given path os-indepently, taking care of known path
      separators.
  
      :param path: path
      :return: filename
      :rtype: str or unicode (depending on given path)