code: def _get_modules_map(self, path=None):
          '''
          Get installed Ansible modules
          :return:
          '''
          paths = {}
          root = ansible.modules.__path__[0]
          if not path:
              path = root
          for p_el in os.listdir(path):
              p_el_path = os.path.join(path, p_el)
              if os.path.islink(p_el_path):
                  continue
              if os.path.isdir(p_el_path):
                  paths.update(self._get_modules_map(p_el_path))
              else:
                  if (any(p_el.startswith(elm) for elm in ['__', '.']) or
                          not p_el.endswith('.py') or
                          p_el in ansible.constants.IGNORE_FILES):
                      continue
                  p_el_path = p_el_path.replace(root, '').split('.')[0]
                  als_name = p_el_path.replace('.', '').replace('/', '', 1).replace('/', '.')
                  paths[als_name] = p_el_path
  
          return pathf _get_modules_map(self, path=None):
          '''
          Get installed Ansible modules
          :return:
          '''
          paths = {}
          root = ansible.modules.__path__[0]
          if not path:
              path = root
          for p_el in os.listdir(path):
              p_el_path = os.path.join(path, p_el)
              if os.path.islink(p_el_path):
                  continue
              if os.path.isdir(p_el_path):
                  paths.update(self._get_modules_map(p_el_path))
              else:
                  if (any(p_el.startswith(elm) for elm in ['__', '.']) or
                          not p_el.endswith('.py') or
                          p_el in ansible.constants.IGNORE_FILES):
                      continue
                  p_el_path = p_el_path.replace(root, '').split('.')[0]
                  als_name = p_el_path.replace('.', '').replace('/', '', 1).replace('/', '.')
                  paths[als_name] = p_el_path
  
          return paths
docs: Get installed Ansible modules
          :return: