def get_process_type_filter(classifiers, subclassing):
    """
    Return filter dictionaries given a set of classifiers.

    :param classifiers: a dictionary with classifiers (note: does *not* support lists)
    :param subclassing: if True, allow for subclasses of the process type
            This is activated only, if an entry point can be found for the process type
            (as well as for a selection of built-in process types)


    :returns: dictionary in QueryBuilder filter language to pass into {"process_type": ... }
    :rtype: dict

    """
    from aiida.common.escaping import escape_for_sql_like
    from aiida.common.warnings import AiidaEntryPointWarning
    from aiida.engine.processes.process import get_query_string_from_process_type_string
    import warnings
    value = classifiers['process_type_string']
    if not subclassing:
        filters = {'==': value}
    elif ':' in value:
        filters = {'or': [{'==': value}, {'like': escape_for_sql_like(
            get_query_string_from_process_type_string(value))}]}
    elif value.startswith('aiida.engine'):
        filters = {'like': '%'}
    else:
        warnings.warn(
            "Process type '{}' does not correspond to a registered entry. This risks queries to fail once the location of the process class changes. Add an entry point for '{}' to remove this warning."
            .format(value, value), AiidaEntryPointWarning)
        filters = {'or': [{'==': value}, {'like': escape_for_sql_like(
            get_query_string_from_process_type_string(value))}]}
    return filters
