got rid of thresholding