naf2conll/naf2conll/main.py
def find_data_dirs(cls, directory,
                       naf_extension=c.NAF_EXTENSION,
                       dirs_to_ignore=c.DIRS_TO_IGNORE):
        """
        Recursively search `directory` for directories containing NAF files.

        Does not return directories whose base name is in `dirs_to_ignore`,
        but does search them.
        """
        dirs_to_ignore = set(dirs_to_ignore)
        for subdir, _, files in os.walk(directory):
            if os.path.basename(subdir) in dirs_to_ignore:
                continue
            if any(file.endswith(naf_extension) for file in files):
                logger.debug(f"subdir: {subdir}")
                yield subdir

        Recursively search `directory` for directories containing NAF files.

        Does not return directories whose base name is in `dirs_to_ignore`,
        but does search them.
        
Recursively search `directory` for directories containing NAF files.
Does not return directories whose base name is in `dirs_to_ignore`,
but does search them.
Recursively search ` directory ` for directories containing NAF files . Does not return directories whose base name is in ` dirs_to_ignore ` but does search them .
def find_data_dirs(cls, directory,
                       naf_extension=c.NAF_EXTENSION,
                       dirs_to_ignore=c.DIRS_TO_IGNORE):
        dirs_to_ignore = set(dirs_to_ignore)
        for subdir, _, files in os.walk(directory):
            if os.path.basename(subdir) in dirs_to_ignore:
                continue
            if any(file.endswith(naf_extension) for file in files):
                logger.debug(f"subdir: {subdir}")
                yield subdir
def find_data_dirs ( cls , directory , naf_extension = c . NAF_EXTENSION , dirs_to_ignore = c . DIRS_TO_IGNORE ) : dirs_to_ignore = set ( dirs_to_ignore ) for subdir , _ , files in os . walk ( directory ) : if os . path . basename ( subdir ) in dirs_to_ignore : continue if any ( file . endswith ( naf_extension ) for file in files ) : logger . debug ( f"subdir: {subdir}" ) yield subdir
Recursively search `directory` for directories containing NAF files.
Recursively search ` directory ` for directories containing NAF files .
"""
        Recursively search `directory` for directories containing NAF files.

        Does not return directories whose base name is in `dirs_to_ignore`,
        but does search them.
        """
cls
directory
naf_extension
dirs_to_ignore