filter.py complete