clening...
fix bugs in filter; add runtime measure and log to FII
overload writeToFile with some options