Towards Recognition-Based Variational Segmentation Using Shape Priors and Dynamic Labeling