added segmentation and radius constraint