Updated thresholding