Weakly Supervised Segmentation by a Deep Geodesic Prior