Brain Tumor Detection using Hidden Markov Chain Algorithm in Image Processing

DOI : 10.17577/IJERTCONV7IS08031

Download Full-Text PDF Cite this Publication

Text Only Version

Brain Tumor Detection using Hidden Markov Chain Algorithm in Image Processing

Pushparani M.K SAP,Dept E&C, MITE,Moodabidri Mangalore, India.

Dr. D Vinod Kumar Professor, Dept E&C VMKVEC,

Salem.TN, India.

Dr. Abdulla Gubbi Professor, Dept E&C BIT,

Mangalore, India.

Abstract The main objective of this paper this is to provide an efficient tool for delineating brain tumors and classification of different types in magnetic resonance images. To achieve this goal, we take into account neighborhood information on using a Hidden Markov Chain [HMC] model. Due to the limited resolution of imaging devices, voxels may be composed of a mixture of different tissue types; this partial volume effect is included to achieve an accurate segmentation of brain tissues. Instead of assigning each voxel to a single tissue class (i.e. hard classification), we compute relative amount of each pure tissue class in each voxel (mixture estimation). Further, a bias field estimation step is added to the proposed algorithm to correct intensity in homogeneities. Furthermore, atlas priors were incorporated using probabilistic brain atlas containing prior expectation about spatial localization of different tissue classes. This atlas is considered as a complementary sensor and the proposed method is extended to multimodal brain MRI without any user-tunable parameter (unsupervised algorithm). To validate this new unifying framework, we present experimental results on both synthetic and real brain images for which ground truth is available. Comparison with other often used techniques demonstrates that accuracy and robustness of this new Markovian Segmentation scheme.

KeywordsMRI; segmentation; HMC;


    The brain is the centre of the nervous system in all vertebrate and invertebrate animals. The finite element model shown in Figure 1.1 includes, for example, white matter, gray matter, cerebrospinal fluid (CSF), bone, major blood vessels, and meninges. However, the model does not have a very detailed geometry.

    A brain tumor is an abnormal growth of cells within the brain or inside the skull, which can be cancerous (malignant) or non-cancerous (benign). It is defined as any intracranial tumor created by abnormal and uncontrolled cell division, normally either in the brain itself or in the cranial nerves or in the brain envelopes (meninges) or skull, pituitary and pineal glands, or spread from cancers primarily located in other organs (metastatic tumors).

    In the evolution of healthcare services, there is an increasing need for greater effective use of imaging data in medical diagnosis and individual risk assessment, treatment selection, and disease prevention. The ultimate challenge is to develop software with intelligence to combine imaging technology with a workable diagnostic system that is capable of detecting tumor in its early stages. It is believed that diagnostic research-based patient-oriented system, with the capability to distinguish the presence of tumors on medical images of healthy people and tumor patients, will be one of the most pressing issues in the near future. The analysis and study of the brain is of great interest due to its potential for

    studying early growth patterns and morphologic changes in the tumor process.

    Figure 1.1 Finite element model

    Recent studies have demonstrated the potential of a decision support system for detecting tumors in medical images, providing radiologists with a second pair of highly trained eyes. It gives doctors access to additional information present in images that have characteristics generally accepted to be associated with cancer, clusters of bright spots that are suggestive of lesions, patterns suggestive of tissue masses or distortions, and mark regions that have the characteristics of lesions or tumors.


    The objective of this paper is to detect brain tumor in images collected from the Diagnostic Centre. The images obtained are based on Magnetic Resonance Imaging technique. In our project work we aim to achieve the following:

    • To provide a fully automated model-based method for tissue classification of MR images of the brain.

    • To propose a segmentation method which is more robust than the existing ones.

    • To develop a base for the application of segmentation methods in multimodal Magnetic Resonance Imaging framework.

    • To propose a more simplified algorithm to show a better clustering of image intensities for analyses.


Figure 3.2 indicates the various steps involved in implementing our proposed method.


voxels. In the last case, the neighbourhood behaviour is regularized by Markov Random Field modelling technique.



      The operations under this group are aimed at defining the object system. The input is a set of multidimensional images, or a computer representation of an object system. The pre- processing is used for loading the input MRI images to the MATLAB environment and also it removes any kind of noise present in the input images.

    2. SCANNING:

      The 3D data cube needs to be transformed into a mono- dimensional sequence via a scan. We use the well-known Hilbert-Peano scan. The interest of this scan is to keep at best the neighbourhood information of the cube.





      p at

      p at

      This is done using probability maps containing prior robabilities of each tissue type at each location. A link to the las is created which will be taken into account for segmentation. One of the interests of the Markov Chain is the possibility of computing exactly the posterior marginals at each location. To obtain a labelling of the image, we use the MPM (Mode of Posterior Marginals) estimator.





      Figure 3.2 Block diagram showing steps involved in the method


      A modified maximum likelihood mixture model algorithm

      [1] using probabilistic images for the segmentation of brain MRI was proposed J.Ashburner and K.J.Friston in 1997. The probability images they used are the means of binary images of white matter (WM), gray matter (GM), and cerebrospinal fluid (CSF) obtained from the segmentation of the original images. However, this method does not take into account neighbourhood information, and therefore the quality of the segmentation is degraded if noise is present in the images. Other methods propose to use a digital brain atlas to initialize the iterative process. A brain atlas is used to segment the brain from non-brain tissue and to compute prior probabilities for each class at each voxel location. A fuzzy atlas, which indicates the probability distribution of each tissue type in the brain, is used as a priori knowledge to correct miss-classified


      The data driven parameters will depend on the observations, on one hand, and on the probability maps of the different tissue of the brain, on the other hand. In the case of unsupervised classification, the statistical properties of the different tissue classes are unknown and must be estimated from the observations. Here the model parameters have been estimated with Stochastic Expectation Maximization (SEM). The SEMis a stochastic variance of the EM algorithm. One of the interests of the SEM algorithm compared to other methods is that the solution does not depend on the initialization making the algorithm more robust.


    The proposed model in our work is compared with the Maximum Likelihood Mixture Model algorithm (MLMM) using probabilistic images [1], and with the algorithm of the HMC without any atlas.

    Comparison with other previously used techniques demonstrates the advantages of this new Markovian segmentation scheme using a probabilistic atlas.


    To do the work in a phased manner it is essential to do the literature survey.

    Stephanie Bricq, Christophe Collet and Jean-Paul Armspach

    [1] presented a new Markovian scheme for MRI segmentation using a priori knowledge obtained from probability maps. Indeed it was proposed to use both triplet Markov chain and a brain atlas containing prior expectations about the spatial localization of the different tissue classes, to

    segment the brain in gray matter, white matter and cerebro- spinal fluid in an unsupervised way.

    Tao Song, MO. M. Jamshidi, Roland. R. Lee and Mingxiong Huangh [2] have designed a novel segmentation algorithm (A modified PNN) for partial volume segmentation in brain MR images.

    Shanthi K. J. and Dr. M. Sasi Kumar [3] have discussed the techniques involved in automatic segmentation of Brain MRI. The schemes presented were Seed growth and Threshold techniques. A hybrid of threshold and seed growth techniques is used in classifying the brain tissues in to White matter, Gray matter and Cerebrospinal Fluid. DICOM images are used for segmenting.

    Jos B, T. M. Roerdink, Arnold Meijster [4] explains in detail the watershed transform, its definitions, algorithms and parallelization strategies. They provided a comprehensive study of several definitions of the watershed transform and the associated sequential algorithms which were used for brain tumor detection.

    1. Woods, S. Cherry and J. Mazziotta [5] discuss rapid automated algorithm for aligning and reslicing PET images. David. D. J, D. C. Hemmy and R. D. Cooter conducted extensive research on Atlas of Three Dimensional reconstruction from computed tomography.

      Boundary Detection in Multidimensions, Pattern Analysis and Machine Intelligence were extensively discussed by J. Udupa, S. Srihari and G. Herman.[6] A PC based 3D imaging system concerned to computerised medical imaging and graphics was designed by S. Raya, J. Udupa, W. Barrett.

      A computational approach to edge detection was devised by Canny. J. [7] in 1986. This technique would give an optimal trade-off between noise smoothing and accuracy by approximating the first derivative of the Gaussian.

      Image processing fundamentals have been explained in a simplified manner by Rafael C. Gonzalez, Richard Eugene Woods [8]. All main stream areas of image processing like enhancement, restoration, segmentation, compression etc., are covered.

      Mark S. Nixon, Alberto S. Aguado [9] have provided an essential guide to the implementation of image processing and computer vision techniques, explaining techniques and fundamentals in a clear and concise manner.

      Digital Image Processing and the corresponding analysis are explained in-depth by B. Chandra and D. Datta. Majumder [10]. All the respective mathematical preliminaries, image processing and analysis, edge and line detection, feature extraction and recognition are dealt conceptually. Fundamentals of Digital Image Processing are also explained by Anil. K. Jain. [11]

      Jayaram K. Udupa [12] has provided in-depth explanation in 3D imaging. All the imaging principle and approaches, its derivatives in clinical research and practice, quantification in 3D imaging and evaluation are clearly considered and made lucid.


    The brain is a soft, spongy mass of tissue. It is protected by the skull and three thin membranes called meninges. Watery fluid called cerebrospinal fluid secreted by choroid plexus cushions the brain. This fluid flows through spaces between the meninges and through spaces within the brain called ventricles. A network of nerves carries messages back and forth between the brain and the rest of the body. Some nerves go directly from the brain to the eyes, ears, and other parts of the head. Other nerves run through the spinal cord to connect the brain with the other parts of the body. Within the brain and spinal cord, glial cells surround nerve cells and hold them in place. The brain directs the things we choose to do (like walking and talking) and the things our body does without thinking (like breathing). The brain is also in charge of our senses (sight, hearing, touch, taste, and smell), memory, emotions, and personality [26] and [20].

    1. BRAIN

      The three major parts of the brain control different activities:

        • Cerebrum – The cerebrum is the largest part of the brain. It is at the top of the brain. It uses information from our senses to tell us what is going on around us and tells our body how to respond. It controls reading, thinking, learning, speech, and emotions. The cerebrum is divided into the left and right cerebral hemispheres, which control separate activities. The right hemisphere controls the muscles on the left side of the body. The left hemisphere controls the muscles on the right side of the body.

        • Cerebellum – The cerebellum is under the cerebrum at the back of the brain. The cerebellum controls balance and complex actions like walking and talking.

        • Brain Stem – The brain stem connects the brain with the spinal cord. It controls hunger and thirst. It also controls breathing, body temperature, blood pressure, and other basic body functions.

      Figure 7.3The brain and nearby structures

      Figure 7.4 Major parts of the brain


      A brain tumor is an intracranial solid neoplasm, a tumor (defined as an abnormal growth of cells) within the brain or the central spinal canal.

      Brain tumors include all tumors inside the cranium or in the central spinal canal. They are created by an abnormal and uncontrolled cell division, normally either in the brain itself (neurons, glial cells (astrocytes, oligodendrocytes, ependymal cells, myelin-producing Schwann cells), lymphatic tissue, blood vessels), in the cranial nerves, in the brain envelopes (meninges), skull, pituitary and pineal gland, or spread from cancers primarily located in other organs (metastatic tumors).

      Any brain tumor is inherently serious and life- threatening because of its invasive and infiltrative character in the limited space of the intracranial cavity. However, brain tumors (even malignant ones) are not invariably fatal. Brain tumors or intracranial neoplasm can be cancerous (malignant) or non-cancerous (benign); however, the definitions of malignant or benign neoplasm differs from those commonly used in other types of cancerous or non-cancerous neoplasm in the body. Its threat level depends on the combination of factors like the type of tumor, its location, its size and its state of development. Because the brain is well protected by the skull, the early detection of a brain tumor only occurs when diagnostic tools are directed at the intracranial cavity. Usually detection occurs in advanced stages when the presence of the tumor has side effects that cause unexplained symptoms.

      Primary (true) brain tumors are commonly located in the posterior cranial fossa in children and in the anterior two- thirds of the cerebral hemispheres in adults, although they can affect any part of the brain.

      Brain tumors are great mimics of other neurological disorders, and many of the common symptoms could indicate other medical conditions. The best way to determine if you or someone you know has a brain tumor is to have a doctor perform a type of brain scan called an MRI.

      Figure 75 MRI Scan Image of brain tumor

      Magnetic Resonance Imaging (MRI), Nuclear Magnetic Resonance Imaging (NMRI), or Magnetic Resonance Tomography (MRT) is a medical imaging technique used in radiology to visualize detailed internal structures. MRI makes use of the property of Nuclear Magnetic Resonance (NMR) to image nuclei of atoms inside the body. MRI provides good contrast between the different soft tissues of the body, which make it especially useful in imaging the brain, muscles, the heart, and cancers compared with other medical imaging techniques such as Computed Tomography (CT) or X-rays. Unlike CT scans or traditional X-rays, MRI uses no ionizing radiation. The MRI detects signals emitted from normal and abnormal tissue, providing clear images of most tumors


    Image segmentation may be defined as a technique, which partitions a given image into a finite number of non- overlapping regions with respect to some characteristics, such as gray value distribution, texture distribution, etc. Segmentation of medical images is required for many medical diagnoses like radiation treatment, planning volume visualization of regions of interest (ROI). Defining boundary of brain tumor and intra cerebral brain hemorrhage, etc. Many approaches are based on fuzzy logic, K means and Neural Networks (NN).

    Segmentation is a collection of methods allowing interpreting spatially close parts of the image as object. Regions (i.e., compact sets) represent spatial closeness naturally and thus are important building steps towards segmentation. Objects in a 2D image very often correspond to distinguishable regions. The object is everything what is of interest in the image (from the particular application point of view). The rest of the image is background. The approach is similar to that used in pattern recognition, i.e., division of the image into set of equivalence classes.


        The simplest method of image segmentation is called the thresholding method. This method is based on a clip-level (or a threshold value) to turn a gray-scale image into a binary image.

        The key of this method is to select the threshold value (or values when multiple-levels are selected). Several popular methods are used in industry including the maximum entropy method, Otsu's method (maximum variance), and et al. k-means clustering can also be used.


    The etymology of the word histogram is uncertain. Sometimes it is said to be derived from the Greek histos 'anything set upright' (as the masts of a ship, the bar of a loom, or the vertical bars of a histogram); and gramma 'drawing, record, writing'. It is also said that Karl Pearson, who introduced the term in 1895, derived the name from "historical diagram".

    Histogram is a graphical representation, showing a visual impression of the distribution of data. It is an estimate of the probability distribution of a continuous variable and was first introduced by Karl Pearson.

    Histograms are used to plot density of data, and often for density estimation: estimating the probability density function of the underlying variable. The total area of a histogram used for probability density is always normalized to 1. If the length of the intervals on the x-axis is all 1, then a histogram is identical to a relative frequency plot.

    In a more general mathematical sense, a histogram is a function mi that counts the number of observations that fall into each of the disjoint categories (known as bins), whereas the graph of a histogram is merely one way to represent a histogram. Thus, if we let n be the total number of observations and k be the total number of bins, the histogram mi meets the following conditions:

    The number of bins k can be assigned directly or can be calculated from a suggested bin width h as:



      The Magnetic Resonance Image (MRI) of the brain from the brain tumor patient is captured and the snapshot is shown in Figure 9.6a and the size of the image is 976X216. Its corresponding histogram is shown in Figure 10.6b.

      figure 9.6 MRI scan image and histogram


      The input image, when captured by the system there is a possibility that the noise may be included due to motion artifacts and due to the procedure involved as it takes more time. Probability of noise added to the data must be taken in to account.

      To evaluate the performance of the algorithm for such extreme situation we consider salt and pepper noise. This

      image data, now as it is corrupted by the noise it is further processed. The results are indicated in the snapshot shown in Figure9.7. The presence of noise is indicated by spotted white dots in the image.

      Figure 9.7 Image with salt and pepper noise


      The cerebrospinal fluid present in the brain is shown Figure9.11. The fluid is present all over the brain. The boundary of the tumor is seen clearly in the presence of black background. The snapshot shown in Figure 10.11 indicates the output image in which the brain tumor is detected.

      Figure 9.11 Brain Tumor image

      Table 9.1 output parameters








Image Segmentation is an important process which shows a wide range of application in the field of medical diagnosis. In this work, the combined use of Triplet Markov Chain Model and Neural network provides good result. The given MRI Brain image is clearly segmented into three parts showing the white matter, gray matter and the cerebral spinal fluid. The tumor present in the brain is visualized and the parameters such as homogeneity and contrast.

The output parameters shown in Table 10.1 consider homogeneity and contrast. A total of around 250 MR images were captured in an age group of 4 to 75 and processed. Its found that our proposed method has yielded 85% of accuracy.

    • Total number of patients: 10

    • Number of images captured per patient: 125

    • Total number of images processed: 1250

    • Accepted images with prescribed accuracy by the doctor: 1060

      In about 15% to 14% the detection was not accurate due to following factors:

      • Small SNR ratio

      • Large artifacts.

      • In older and very young patients more


  1. Stephanie Bricq, Christophe Collet and Jean-Paul Armspach, Triplet Markov Chain for 3d MRI Brain Segmentation Using a Probabilistic Atlas.

  2. Tao Song, Mo M. Jamshidi, Roland R. Lee, and Mingxiong Huang, A Modified Probabilistic Neural Network for Partial Volume Segmentation in Brain MR Image, IEEE Trans. on Neural Network, Vol. 18, No. 5,2007

  3. Shanthi K.J and Dr. M. Sasi Kumar, Skull stripping and Automatic Segmentation of Brain MRI using Seed Growth and Threshold Techniques, 2007.

  4. J. Roerdink and A. Meijster, The watershed Transform: Definitions, Algorithms and Parallelization Strategies, Fundamenta Informaticae, 41, pp. 187-228, 2001 IOS Press.

  5. R. Woods, S. Cherry and J. Mazziotta, Rapid automated for aligning and releasing PET images, Journal of Computer Assisted Tomography, 16:620-633.1992

  6. J. Udupa, S. Srihari and G. Herman, Boundary detection in Multidimensions, IEEE Transactions on Pattern Analysis and Machine Intelligence. PAMI-4:41-50, 1982

  7. Canny J, A computational approach to edge detection, IEEE Trans. on Patt. Anal. and Mach. Intell. , PAMI-8:679-698, 1986.

  8. Rafael. C. Gonzalez and Richard C. Woods, Digital image processing, Addison-Wesley Publishing Company, 1992.

  9. Feature extraction and imageprocessing by Mark S. Nixon,

    Albert S. Aguado, Edition: 2, published by Academic Press, 2008

  10. B. Chanda and D. Dutta Majumder, Digital Image Processing and Analysis, Prentice Hall, India 2000.

  11. Jain. Anil K., Fundamentals of Digital Image Processing, Prentice Hall, Englewood Cliffs, NJ, 1989.

  12. Jayaram K. Udupa, and Gabor T. Herman, 3D Imaging in Medicine, second edition

  13. Willis J. Tompkins, Biomedical Digital Signal Processing, Prentice Hall, India, 1995.

  14. IEEE Signal Processing Magazine, Vol 23, No 3, May 2006.

Leave a Reply

Your email address will not be published.