code: def __filename_to_modname(self, pathname):
          
          filename = PathOperations.pathname_to_filename(pathname)
          if filename:
              filename = filename.lower()
              filepart, extpart = PathOperations.split_extension(filename)
              if filepart and extpart:
                  modName = filepart
              else:
                  modName = filename
          else:
              modName = pathname
          return modName
docs: @type  pathname: str
          @param pathname: Pathname to a module.
  
          @rtype:  str
          @return: Module name.