a generalization of contour line based