bugs in filter model
merge christopher's changes