added thresh variable to threshold and blondel stuff
added thresh variable to threshold and blondel stuff