Dimensionality Reduction for Improving Out-of-Distribution Detection in Medical Image Segmentation