def find(self, package, **kwargs):
        """
        Find method.

        Args:
            package (str): package to find.
            **kwargs (): additional keyword arguments.

        Returns:
            PackageSpec: the PackageSpec corresponding to the package, or None.
        """
        if not exists(package):
            return None
        name, path = None, None
        enforce_init = kwargs.pop('enforce_init', True)
        if isdir(package):
            if isfile(join(package, '__init__.py')) or not enforce_init:
                name, path = basename(package), package
        elif isfile(package) and package.endswith('.py'):
            name, path = splitext(basename(package))[0], package
        if name and path:
            return PackageSpec(name, path)
        return None
Find method.

        Args:
            package (str): package to find.
            **kwargs (): additional keyword arguments.

        Returns:
            PackageSpec: the PackageSpec corresponding to the package, or None.