tarted working on making UT work, new method added for segmentation