Image Segmentation with Adaptive Spatial Priors from Joint Registration