Fixed bugs in filtering and added extra filters to profiling