Remove useless import and a condition for the segmentation