oh also if you're looking for other useful features, a highpass + average filter. average the image and save that color, blur the image to a large size (optionally downsampling first to run faster however that will reduce quality in many cases), gaussian blur, subtract from original, then add back the average color. this will remove large scale variation like a soft shadow along it or shading on a round object, but will keep the original base color and the details.