added plotting of segmented image