added comments to image analysis functions