<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _flatten(container):
 """Flatten arbitrary nested list of filters into a 1-D list """

    if isinstance(container, string_types):
        container = [container]
    for elem in container:
        if isinstance(elem, string_types) or is_filter_tuple(elem):
            yield elem
        else:
            for elem2 in _flatten(elem):
                yield elem2