1. A method, comprising: determining gradient magnitude values at respective pixels of a given image; thresholding the gradient magnitude values with a global threshold to produce thresholded gradient magnitude values; segmenting the pixels into respective groups in accordance with a watershed transform of the thresholded magnitude values; and generating a classification record labeling as background pixels ones of the pixels segmented into one of the groups determined to be largest in size and labeling as non-background pixels ones of the pixels segmented into any of the groups except the largest group; wherein the determining, the thresholding, the segmenting, and the generating are performed by a computer system.