added create_segment function