Trying with different thresholding algorithms