starting filter optimization
added batch support to set