Exact Bayesian Segmentation