Create Adaptive Thresholding

finds a threshold adaptively depending on the image