import re


def __filter_modules(item):
    """
    Filter function to detect processor modules and packages

    :param str item: the item to be tested with this filter
    """
    exclude = (
        re.escape('__init__.py'),
        re.escape('base.py')
    )
    pattern = re.compile('|'.join(exclude))
    return not pattern.search(item)