Abstract. In this paper we propose a two-step mutual informationbased algorithm for medical image segmentation. In the first step, the image is structured into homogeneous regions, by maximizing the mutual information gain of the channel going from the histogram bins to the regions of the partitioned image. In the second step, the intensity bins of the histogram are clustered by minimizing the mutual information loss of the reversed channel. Thus, the compression of the channel variables is guided by the preservation of the information on the other. An important application of this algorithm is to preprocess the images for multimodal image registration. In particular, for a low number of histogram bins, an outstanding robustness in the registration process is obtained by using as input the previously segmented images.