SMS dit: Robust higher order potentials for enforcing label consistency