attempt to speedup filtering