The Principles and Foundations of Semantic Segmentation