Comparison of Image Compression and Enhancement Techniques for Image Quality in Medical Images.

Similar documents
A Novel Approach of Compressing Images and Assessment on Quality with Scaling Factor

2. REVIEW OF LITERATURE

Audio and Speech Compression Using DCT and DWT Techniques

AN ERROR LIMITED AREA EFFICIENT TRUNCATED MULTIPLIER FOR IMAGE COMPRESSION

SECTION I - CHAPTER 2 DIGITAL IMAGING PROCESSING CONCEPTS

A SURVEY ON DICOM IMAGE COMPRESSION AND DECOMPRESSION TECHNIQUES

Lossy Image Compression Using Hybrid SVD-WDR

Comparative Analysis of Lossless Image Compression techniques SPHIT, JPEG-LS and Data Folding

Audio Signal Compression using DCT and LPC Techniques

Compression and Image Formats

Image Compression Based on Multilevel Adaptive Thresholding using Meta-Data Heuristics

Chapter 9 Image Compression Standards

An Adaptive Wavelet and Level Dependent Thresholding Using Median Filter for Medical Image Compression

Sensors & Transducers 2015 by IFSA Publishing, S. L.

Design and Testing of DWT based Image Fusion System using MATLAB Simulink

Image Compression Using SVD ON Labview With Vision Module

Improvement in DCT and DWT Image Compression Techniques Using Filters

Efficient Image Compression Technique using JPEG2000 with Adaptive Threshold

Lossless Huffman coding image compression implementation in spatial domain by using advanced enhancement techniques

Image Smoothening and Sharpening using Frequency Domain Filtering Technique

Empirical Study on Quantitative Measurement Methods for Big Image Data

Image Compression Using Hybrid SVD-WDR and SVD-ASWDR: A comparative analysis

Lossy and Lossless Compression using Various Algorithms

Discrete Wavelet Transform For Image Compression And Quality Assessment Of Compressed Images

Digital Media. Lecture 4: Bitmapped images: Compression & Convolution Georgia Gwinnett College School of Science and Technology Dr.

INTERNATIONAL JOURNAL OF PURE AND APPLIED RESEARCH IN ENGINEERING AND TECHNOLOGY

Coding and Analysis of Cracked Road Image Using Radon Transform and Turbo codes

Keywords Fuzzy Logic, ANN, Histogram Equalization, Spatial Averaging, High Boost filtering, MSE, RMSE, SNR, PSNR.

An Enhanced Least Significant Bit Steganography Technique

A Spatial Mean and Median Filter For Noise Removal in Digital Images

International Journal of Digital Application & Contemporary research Website: (Volume 1, Issue 7, February 2013)

A COMPARATIVE ANALYSIS OF DCT AND DWT BASED FOR IMAGE COMPRESSION ON FPGA

REVIEW OF IMAGE COMPRESSION TECHNIQUES FOR MULTIMEDIA IMAGES

DEVELOPMENT OF LOSSY COMMPRESSION TECHNIQUE FOR IMAGE

IMPLEMENTATION OF IMAGE COMPRESSION USING SYMLET AND BIORTHOGONAL WAVELET BASED ON JPEG2000

Artifacts and Antiforensic Noise Removal in JPEG Compression Bismitha N 1 Anup Chandrahasan 2 Prof. Ramayan Pratap Singh 3

SPIHT Algorithm with Huffman Encoding for Image Compression and Quality Improvement over MIMO OFDM Channel

JPEG2000: IMAGE QUALITY METRICS INTRODUCTION

ECE/OPTI533 Digital Image Processing class notes 288 Dr. Robert A. Schowengerdt 2003

A Study on Image Enhancement and Resolution through fused approach of Guided Filter and high-resolution Filter

A Study On Preprocessing A Mammogram Image Using Adaptive Median Filter

Satellite Image Compression using Discrete wavelet Transform

Published by: PIONEER RESEARCH & DEVELOPMENT GROUP ( 1

HYBRID MEDICAL IMAGE COMPRESSION USING SPIHT AND DB WAVELET

SYLLABUS CHAPTER - 2 : INTENSITY TRANSFORMATIONS. Some Basic Intensity Transformation Functions, Histogram Processing.

Enhanced DCT Interpolation for better 2D Image Up-sampling

Image Enhancement in Spatial Domain

Analysis of ECG Signal Compression Technique Using Discrete Wavelet Transform for Different Wavelets

INSTITUTE OF AERONAUTICAL ENGINEERING Dundigal, Hyderabad

Lossless Image Compression Techniques Comparative Study

Image Compression and Decompression Technique Based on Block Truncation Coding (BTC) And Perform Data Hiding Mechanism in Decompressed Image

Comparative Analysis between DWT and WPD Techniques of Speech Compression

Module 6 STILL IMAGE COMPRESSION STANDARDS

Image Quality Estimation of Tree Based DWT Digital Watermarks

Anna University, Chennai B.E./B.TECH DEGREE EXAMINATION, MAY/JUNE 2013 Seventh Semester

On the Performance of Lossless Wavelet Compression Scheme on Digital Medical Images in JPEG, PNG, BMP and TIFF Formats

A Hybrid Technique for Image Compression

Ch. 3: Image Compression Multimedia Systems

Performance Evaluation of H.264 AVC Using CABAC Entropy Coding For Image Compression

Images and Graphics. 4. Images and Graphics - Copyright Denis Hamelin - Ryerson University

Image Quality Assessment for Defocused Blur Images

Image Compression Using Huffman Coding Based On Histogram Information And Image Segmentation

Subjective evaluation of image color damage based on JPEG compression

Tri-mode dual level 3-D image compression over medical MRI images

UNEQUAL POWER ALLOCATION FOR JPEG TRANSMISSION OVER MIMO SYSTEMS. Muhammad F. Sabir, Robert W. Heath Jr. and Alan C. Bovik

LIST 04 Submission Date: 04/05/2017; Cut-off: 14/05/2017. Part 1 Theory. Figure 1: horizontal profile of the R, G and B components.

Keywords-Image Enhancement, Image Negation, Histogram Equalization, DWT, BPHE.

A Novel Approach for MRI Image De-noising and Resolution Enhancement

Comparative Analysis of WDR-ROI and ASWDR-ROI Image Compression Algorithm for a Grayscale Image

An Analytical Study on Comparison of Different Image Compression Formats

A New Image Steganography Depending On Reference & LSB

ScienceDirect. A Novel DWT based Image Securing Method using Steganography

Image Processing Computer Graphics I Lecture 20. Display Color Models Filters Dithering Image Compression

ABSTRACT I. INTRODUCTION

Digital Image Processing Introduction

A Modified Image Coder using HVS Characteristics

B.E, Electronics and Telecommunication, Vishwatmak Om Gurudev College of Engineering, Aghai, Maharashtra, India

A new quad-tree segmented image compression scheme using histogram analysis and pattern matching

HIGH QUALITY AUDIO CODING AT LOW BIT RATE USING WAVELET AND WAVELET PACKET TRANSFORM

The Scientist and Engineer's Guide to Digital Signal Processing By Steven W. Smith, Ph.D.

Image compression using Thresholding Techniques

A Review on Image Fusion Techniques

Image Compression Using Haar Wavelet Transform

Linear Gaussian Method to Detect Blurry Digital Images using SIFT

Assistant Lecturer Sama S. Samaan

Image Compression Technique Using Different Wavelet Function

Digital Image Processing 3/e

A Histogram based Algorithm for Denoising Images Corrupted with Impulse Noise

Speech Compression Using Wavelet Transform

Performance Optimization of Hybrid Combination of LDPC and RS Codes Using Image Transmission System Over Fading Channels

PERFORMANCE EVALUATION OFADVANCED LOSSLESS IMAGE COMPRESSION TECHNIQUES

Comparing CSI and PCA in Amalgamation with JPEG for Spectral Image Compression

Survey on Image Contrast Enhancement Techniques

Implementation of Barcode Localization Technique using Morphological Operations

MULTIMEDIA SYSTEMS

Watermarking-based Image Authentication with Recovery Capability using Halftoning and IWT

Templates and Image Pyramids

Image compression using hybrid of DWT, DCT, DPCM and Huffman Coding Technique

Pooja Rani(M.tech) *, Sonal ** * M.Tech Student, ** Assistant Professor

Image Extraction using Image Mining Technique

Transcription:

Master Thesis Electrical Engineering February 2017 Master of Science in Electrical Engineering with Emphasis on Signal Processing Comparison of Image Compression and Enhancement Techniques for Image Quality in Medical Images. Submitted by Sai Virali Tummala Veerendra Marni Department of Applied Signal Processing Blekinge Institute of Technology SE 371 79 Karlskrona, Sweden

This thesis is submitted to the Department of Applied Signal Processing at Blekinge Institute of Technology in partial fulfillment of the requirements for the degree of Master of Science in Applied Signal Processing. Contact Information: Author(s): Sai Virali Tummala E-mail: satu15@student.bth.se Veerendra Marni E-mail: vema15@student.bth.se University adviser: Irina Gertsovich Department of Applied Signal Processing Dept. Applied Signal Processing Internet : www.bth.se Blekinge Institute of Technology Phone : +46 455 38 50 00 SE 371 79 Karlskrona, Sweden Fax : +46 455 38 50 57

Abstract Context: Image Processing is the processing of images, series of images or videos by using mathematical operations by using any form of signal processing techniques. Image Compression and Image Enhancement are the most widely used techniques in Image Processing. Now a day there is an increasing need of these techniques in the medical field. This thesis is focused on the performance quality comparison of medical images using Image Compression and Enhancement Techniques. This analysis is used to suggest the better techniques for compression and enhancement of medical images. Objectives: In this study, the main objective is to attain an efficient output of a medical image. This undergoes a series of steps starting with compression and then followed by the enhancement of the medical image to get an enhanced output. We provide a detailed analysis of all the techniques involved in this process. The images quality is then assessed on various performance parameters. Methods: A detailed literature research has been done to study the various techniques in both image compression and enhancement. The performance metrics are considered by understanding the literature research from various papers. Both the lossy and lossless methods are used in image compression. The lossy technique has been done in both Discrete Cosine Transform (DCT) and Discrete Wavelet Transform (DWT) and lossless in both Run Length Encoding (RLE) and Block Truncation process. Further, the enhancement of the compressed outputs is performed using Image Intensity Adjustment, Adaptive Histogram Equalization (AHE) and Morphological Operations. The results are obtained and the performance metrics are compared. MAT- LAB is used for the coding purpose. Results: The results are calculated using the performance metrics PSNR, MSE and SSIM where the values for each technique are tabulated. Then plots for each image and for each performance metric are plotted. Through these outputs we compare different performance parameters by adjusting the coefficients and also the block sizes. Conclusions: With a detailed analysis and logical comparison of the performance metrics we conclude the better performance metric than the other and also which combinations of compression and enhancement techniques are better with each other. Keywords: AHE, Block Truncation Process, DCT, DWT, Image Compression, Image Enhancement, Morphological Operations, RLE.

Acknowledgement We would like to express our deep sense of sincere gratitude to our supervisor Irina Gertsovich for her continuous support and guidance in each and every aspect to achieve the aim of this thesis work. This helped us enhance our skills and the quality of our thesis. I would also like to extend my gratitude towards my University, BTH, because of which we are what we are today. Also, we would like to heart fully thank our friend Suveen Kumar Vundavalli and Sri Krishna Jayanthi who extended their support directly or indirectly for us in building up this project. And also we like to thank all our friends for their continuous love and support. And also finally, last but not the least, we would like to thank our parents for making us what we are today. Their constant support, love and encouragement have made us achieve all our goals in our life in a better way. Thank You!!! ii

Abbreviations AHE BTC CR DCT DWT HL HH JPEG LL LH MO MRI MSE PSNR RLE SSIM Adaptive Histogram Equalization Block Truncation Coding Compression Ratio Discrete Cosine Transform Discrete Wavelet Transform High low Low High Joint Photographic Experts Group Low Low Low High Morphological Operations Magnetic Resonance Imaging Mean Square Error Peak Signal to Noise Ratio Run Length Encoding Structural Similarity Index Modulation iii

Contents Abstract i 1 Introduction 1 1.1 Motivation............................... 1 1.2 Aims and Objectives......................... 2 1.3 Research Questions.......................... 2 1.4 Documentation Framework...................... 3 2 Related Work 4 3 Methodology 6 3.1 Theoreotical Background....................... 6 3.2 Image Compression Techniques................... 6 3.2.1 Lossy Techniques....................... 8 3.2.1.1 Discrete Cosine Transform (DCT)........ 8 3.2.2 Discrete Wavelet Transform (DWT)............. 9 3.2.3 Lossless Compression..................... 9 3.2.3.1 Run Length Encoding (RLE)........... 10 3.2.3.2 Block Truncation Coding............. 10 3.2.4 Enhancement Techniques................... 11 3.2.4.1 Adaptive Histogram Equalization (AHE)..... 11 3.2.5 Morphological Operations (MO)............... 12 3.3 Performance Metrics......................... 12 3.3.1 Peak Signal to Noise Ratio (PSNR)............. 12 3.3.2 Mean Square Error (MSE).................. 13 3.3.3 Structural Similarity Index Modulation (SSIM)...... 13 4 Results & Analysis 14 4.1 Output Image for 111.tif....................... 14 4.2 Output Image for 222.tif....................... 17 4.3 Output Image for 333.tif....................... 20 4.4 Tabular Forms of Performance Parameters............. 24 4.4.1 Performance Metrics Tabular Form for 111.tif....... 24 4.4.2 Performance Metrics Tabular Form for 222.tif....... 25 iv

4.4.3 Performance Metrics Tabular Form for 333.tif....... 26 4.5 Plots for PSNR, MSE and SSIM for the image database...... 27 5 Conclusion & Future Work 31 References 32 v

List of Figures 3.1.1 Block Diagram of the Compression and Enhancement Process... 7 4.1.1 Lossy compression of medical image using DCT.......... 14 4.1.2 Lossy compression of medical image using DWT.......... 15 4.1.3 Enhancement of DCT compressed image using AHE and MO... 15 4.1.4 Enhancement of DWT compressed image using AHE and MO.. 15 4.1.5 Lossless Compression using BTC and RLE............. 16 4.1.6 Enhancement of BTC compressed image using AHE and MO... 16 4.1.7 Enhancement of RLE compressed image using AHE and MO... 17 4.2.1 Lossy compression of medical image using DCT.......... 17 4.2.2 Lossy compression of medical image using DWT.......... 18 4.2.3 Enhancement of DCT compressed image using AHE and MO... 18 4.2.4 Enhancement of DWT compressed image using AHE and MO.. 18 4.2.5 Lossless Compression using BTC and RLE............. 19 4.2.6 Enhancement of BTC compressed image using AHE and MO... 19 4.2.7 Enhancement of RLE compressed image using AHE and MO... 20 4.3.1 Lossy compression of medical image using DCT.......... 20 4.3.2 Lossy compression of medical image using DWT.......... 21 4.3.3 Enhancement of DCT compressed image using AHE and MO... 21 4.3.4 Enhancement of DWT compressed image using AHE and MO.. 21 4.3.5 Lossless Compression using BTC and RLE............. 22 4.3.6 Enhancement of BTC compressed image using AHE and MO... 22 4.3.7 Enhancement of RLE compressed image using AHE and MO... 23 4.5.1 PSNR plot for all medical images database............. 28 4.5.2 SSIM plot for all medical images database.............. 29 vi

List of Tables 4.1 Image 111.tif tabular form...................... 24 4.2 Image 222.tif tabular form...................... 25 4.3 Image 333.tif tabular form...................... 26 vii

Chapter 1 Introduction As in today s world of emerging technology where most of the data is recorded in digital format, virtually all image interpretation and analysis involves some elements of digital processing. This digital image processing involves the processing of images, series of images or videos by using mathematical operations by using any form of signal processing techniques. Image compression and image enhancement are the most widely used techniques in image processing. Different types of images like binary images, indexed or pseudo colored images, grayscale images, true color images also known as RGB images are generally used in image processing. Image Processing is of generally digital image processing but there are also analog and optical image processing possible.image compression is an efficient technique to reduce the size of graphical file and also reduce the storage requirement area [1]. Medical images like Magnetic Resonance Imaging (MRI) scans, X-ray images are the most used images these days in the medical field. As there is an emerging growth of population these days so are the health issues of the people. The different cases of number of patients and their records are maintained in the hospitals. So, for storing all the case history of a patient there are a number of medical images that has to be stored in the system database. In this regard the medical images are compressed using several techniques and thus images are stored and transmitted from one system to another for the ease of communication. So, in this project the medical images undergo both compression and enhancement techniques consecutively. And later on the performance quality of the images are tested on different performance parameters which are mostly used in to check the performance of compression and enhancement techniques. 1.1 Motivation Image compression and image enhancement techniques are the most widely used techniques these days in the field of medical images. So, in this master thesis we compare the performance quality of the different compression and enhancement 1

Chapter 1. Introduction 2 techniques based on different performance metrics. The basic idea is to consider different medical images and perform compression techniques on the images. Then the images are again restored back by enhancing them. Then, we calculate the performance measuresniques of the compression and enahancement tech by using different performance parameters like peak signal to noise ratio (PSNR), mean square error(mse) and structural similarity index modulation(ssim). Our main motive of this thesis is to compare different techniques on the same medical images and see how the performance varies on different combinations accordingly.thus the quality of the output image is compared with the input image and the performance of the combinatons are analysed. 1.2 Aims and Objectives The main aim of this thesis is the performance quality comparison of medical images using both image compression and enhancement techniques. The objectives mainly include: Selection of necessary medical image database from the open source libraries available. Compression of the medical images using both lossy and lossless compression techniques. Enhancing the compressed images using different enhancement techniques. Comparison and evaluation of the quality of the obtained output images in each case with respect to the original image. 1.3 Research Questions The research questions discussed in this thesis are : What are the methods or techniques used for image compression? What are the methods or techniques used for image enhancement? What are the performance metrics that need to be considred to compare the performance results of different combinations of image compression and enhancement methods?

Chapter 1. Introduction 3 1.4 Documentation Framework The document is organized as mentioned below. Chapter 1 gives a brief introduction about the thesis in which way image processing is being used widely these days in the field of medical images. This section also deals with the main motive of the thesis and the aims and objectives of this thesis. This is further followed by research questions and documentation framework. Chapter 2 discusses the various projects or papers that are already published on the image compression and image enhancement of medical images. Chapter 3 mainly focuses on the various methods or techniques used for the performance quality comparison of medical images. Here we first discuss about the literature review that has been done for this thesis project and then followed by compression and enhancement techniques in this project in detail. Then the performance metrics are analyzed one after the other and how each metric is implemented. Chapter 4 includes the results and the analysis part of each technique. The values that are obtained from each performance metric are tabulated and the respective graphs plotted for each metric are included in this section. The results are analyzed and validated. Chapter 5 gives a clear conclusion of the thesis project based on the above analyzed and validated results. The future scope of this thesis is also mentioned here in this section.

Chapter 2 Related Work This thesis mainly focuses on the concepts of image compression and image enhancement techniques.in this thesis project work a literature review has been made in order to assess the progress made in the field of image compression and image enhancement techniques on medical images. In [2], the author mainly concentrates on the types on compression techniques available for medical image compression and their classifications. In this paper the author also used performance parameters for the comparison of the images compressed. These techniques have been used for comparing different compression techniques and the values of peak signal to noise ratio (PSNR) are calculated. In [3], we will come to know a critical review on the image enhancement techniques that are being used for the medical gray scale images. In this paper the techniques are classified into frequency and spatial domains and the advantages and disadvantages of these techniques are discussed. In [4], the author focuses on developing some simple functions to compute discrete cosine transform (DCT) and compress the images. The 2D DCT is used for the compression of images in this paper. The author uses one dimensional and two dimensional DCT as well. Here, the image is converted into 8*8 block matrix for compression and the quantization technique is also used for compression process. This entire process is followed by inverse 2D DCT for reverse decoding of the image that has been compressed. In [5], the author uses 2D Discrete Wavelet Transforms to decompose the image both spatial and spectral coefficients. Here, the image is divided into 4 parts of low-low(ll), low-high(lh), high-low(hl), and high-high(hh). And the images are compressed using discrete wavelet transform (DWT) and compared using performance parameters. In [6], the author compresses the images using DWT and then compares the performance using metrics like PSNR, mean square error (MSE) and compression ratio (CR). In [7], the author uses a hybrid combination of both DCT and DWT for the compression of medical gray scale images. Here the author shows that DWT with a two-threshold method named "improved-dwt" provides a better quality of image compared to DCT and to DWT with a one-threshold method. Finally, the combination of the two techniques, named improved-dwt-dct compres- 4

Chapter 2. Related Work 5 sion technique yields a better performance than DCT based joint photographic experts group (JPEG) in terms of PSNR. In [8], the author shows a comparison between the RLE and Huffman algorithms for lossless data compression of medical images. This study points to the effectiveness of the algorithm in the process of reducing the size of the files. For the further study in the compression techniques, the author in [9], used some modified block truncation coding along with other algorithms to compress the image. In this case this method has provided an image that is more robust and requires very little error protection overhead. And for the enhancement of the compressed images the author in [10], has proposed an image enhancement technique for image contrast enhancement using a histogram modified framework and its applications. The experimental results show the effectiveness of the algorithm in comparison to other enhancement algorithms. The author in [11], also used morphological filtering for image enhancement for cleaning the image from various types of noise using the morphological operations like erosion, dilation for the enhancement of the images.

Chapter 3 Methodology 3.1 Theoreotical Background The performance metrics that are to be used for comparison of the compressed and enhanced images were selected by reading several related research papers and journals. The methodology to reach the aim of this project involves an experimentation part from which the required data and graphical representations can be obtained to make an appropriate analysis. The experimentation includes collecting the values of the selected performance metrics and plotting the graphs for the values obtained. The experiments were performed using MATLAB software. For this purpose we need medical images to test and compare the techniques. So a medical database of nearly one hundred images is collected from an open source in the Internet.This database is a collection of 100 medical gray scale images taken from different open sources for testing in the code. The dimensions of the images taken are nearly.the images that are collected are free from the copyrights issues and are open for the public to use them. The block diagram in fig 3.1 depicts the research methodology followed in this thesis to achieve the desired goal of this thesis. 3.2 Image Compression Techniques Image Compression addresses the problem of reducing the irrelevance and redundancy of the image data in order to be able to store or transmit data in efficient form. As there is a wide growth in medicine field in day to day life there is also a great need for image compression techniques for storing abundant data and information. Image Compression is nothing but the size of the image is actually reduced in size without degrading the quality of the image[12]. The reduced file size thus helps in storing more number of images in a file and for easy sending and communication to others[13]. 6

Chapter 3. Methodology 7 Figure 3.1.1: Block Diagram of the Compression and Enhancement Process. There are several ways in which images can be compressed. Image can be compressed either with or without data loss. Depending on whether the data is lost or not image compression is mainly of two types, Lossy Compression Lossless Compression There are many techniques in both lossy and lossless techniques. But in our thesis project we considered comparing only two lossy and two lossless techniques respectively. The techniques used in lossy image compression are, Discrete Cosine Transform (DCT) Discrete Wavelet Transform (DWT) The techniques used in lossless image compression are, Run Length Encoding (RLE) Block Truncation Coding (BTC)

Chapter 3. Methodology 8 3.2.1 Lossy Techniques Lossy compression techniques are those techniques in which the compression of the image is done with the loss of some information. The compressed image looks similar to the original image but there is some loss in the information which can be difficult to see in the compressed image. The lossy techniques that are used in the compressing schemes such as jpg, png etc. In this thesis we considered several gray scale medical images and compressed them. Lossy compression comparatively has higher compression ratio than the lossless techniques. Performance of the lossy techniques are mainly measured by such metrics as compression ratio, signal to noise ratio and speed of encoding and decoding. The techniques used in this project for the lossy compression of medical images are, Discrete Cosine Transform (DCT) Discrete Wavelet Transform (DWT) 3.2.1.1 Discrete Cosine Transform (DCT) The main objective of the image compression systems based on transform techniques is to store data efficiently and also to provide a good tradeoff between the compression rates and the signal to noise ratios. In this thesis we have considered DCT as DCT gives better results in terms of mean square error and compression ratio values compared to any other technique for gray scale medical images[4]. DCT is in the base of JPEG image compression. DCT is also fast compared to others and is also best for images with smooth edges. It transforms a signal from its spatial domain to frequency domain. The images after reconstruction are inversely proportional to the values of quantization. It packs the most important information into few coefficients. A gray scale medical image is taken and compressed using DCT and inverse DCT is used for reconstructing back. This process is done twice.this process of compression is done twice so as to reduce the spatial resolution of the image in the first step and after this the image is divided into blocks and compressed again in the second step.so the first step is done using matlab formula, And the secondly, the image is split into blocks of 8 by 8 where each block undergoes 2dct. The encoding and decoding process follows for full compression process using IDCT to support 8 by 8 pixel per precision. In this compression all the coefficients from the top left corner in the matrix are considered so we have taken a number i.e., 20000 so that the high data is compressed well. So, after the general compression and decompression process the output may not be in the original range (0, 255), so the output is resized. So, thus the out compressed image is obtained which is compared with the original input for errors.

Chapter 3. Methodology 9 3.2.2 Discrete Wavelet Transform (DWT) One of the most widely used transform techniques for image compression of medical images using wavelets is Discrete Wavelet Transform (DWT). This DWT is very useful for compressing signal and also shows better results for medical gray scale images. While using DWT the important parameters that are taken into consideration are testing the image, wavelet function, number of iterations and calculation complexity. These wavelets transforms are used to process and improve signals in fields like medical imaging where image degradation is not tolerated. The same input image which is taken earlier for DCT is now compressed using the DWT compression technique. The image is converted from mat to gray and then it is divided into 4 bits in the form of (low, low), (low, high), (high, low), (high, high). The image is undergone through DWT compression and then the image is again resized to original size. In this way the image is compressed using DWT. The performance metrics are then calculated using PSNR, MSE, and SSIM and are tabulated for the further comparison with the other techniques. 3.2.3 Lossless Compression The lossless compression technique is the other most important techniques in image compression techniques. In this lossless compression technique, the compression of the image is done without incurring any major data loss in the image. This means that the image will be compressed but there will no significant loss in data which means all the useful information is not removed through compression. This lossless compression due its capacity of compressing the image without any data loss is used as the best method for image compression of medical images. Lossless ompression finds its great use in medical field due to its rapid growth in recent times. As the number of hospitals and number of case records are increasing day by day there is also an increasing growth in need for compression of images for their storage and easy transmission. So, in these cases a case record is very important to be stored in a compressed format and also without any loss in data because of compression. In this way lossless compression satisfies both the cases. Nevertheless, this only comes at the expense of obtaining low compression rate values compared to lossy techniques. Most lossless compressions use entropy encoding methods for the compression.

Chapter 3. Methodology 10 The lossless compression that we used here in our thesis for compressing the gray scale medical images and to compare the performance metrics are, Run Length Encoding (RLE) Block Truncation Coding (BTC). 3.2.3.1 Run Length Encoding (RLE) In the lossless compression techniques, one of the most widely used encoding techniques is Run length encoding (RLE). RLE technique actually compresses the medical images without losing the important information or data. This technique compresses the images with a continuous long sequence into a single data sequence. Run Length Encoding is mostly in use din compressing black and white images as this gives better results in compression of images. In this thesis, the medical image is selected from the medical images database from an open source and is tested using matlab. The image is first converted from mat to gray and is given as an input for compression. Image intensity adjustment algorithm is also used here to enhance the contrast of the image. This algorithm does not provide any significant change in the original file. The loaded image is further converted into the desired form and the for loop is implemented. The iteration is repeated as long as the coefficients of the images used are iterated and the image is compressed into a single sequence. Then the image is iterated and then the loop is removed. Then the RLE out compressed image is obtained and the lossless compression using RLE is obtained. 3.2.3.2 Block Truncation Coding In this thesis project we used Block Truncation Coding as another compression method for gray scale medical images. This method is used as one of the lossless compression technique for medical images. In many cases, RLE and BTC for lossless compression are used together as a combination for achieving the compression outputs. This technique is implemented as a set of nodes and can be easily stored as a regular set of arrays [14].Here in this project we used block truncation coding as another compression method for gray scale medical images. This method is used as one of the lossless compression technique for medical images. In this project the images from the open source medical image database is selected and taken as the input. The block size of the images is adjusted according to which we gt the desired output. We used BTC in some parts so as to allow the separation of the image into blocks. This technique is followed by column

Chapter 3. Methodology 11 filtering so that the entire column values are adjusted.the BTC approach has the advantage of being extremely easy to implement; moreover, it often possesses good performance characteristics relative to other techniques even in the presence of many channel errors.[15]. Now thus by implementing this process we get the required BTC compressed image as the required output. The performance metrics are measured, tabulated and plotted as graphs respectively. 3.2.4 Enhancement Techniques Image enhancement is the popular and the most widely known technique of image processing. Many images like medical images, satellite images, aerial images and even real life photography suffer from noise and poor contrast.image enhancement algorithms offer a wide variety of approaches for modifying images to achieve visually acceptable images. The choice of such techniques is a function of the specific task, image content, observer characteristics, and viewing conditions. The point processing methods are most primitive, yet essential image processing operations and are used primarily for contrast enhancement [16]. Enhancement techniques improve the quality of the image view, blurring, noise and increasing contrast and improve the borders and sharpness of the image. The enhancement methods can broadly be divided in to the following two categories, Spatial domain Frequency domain Spatial domain and frequency domain include techniques like point processing, image smoothening, edge detection and image sharpening. The techniques used in this thesis are spatial domain which deal with the image pixels and enhance the contrast and the compressed medical images are well enhanced by image adjustment. The techniques used in thesis to enhance the compressed medical images are, Adaptive Histogram Equalization (AHE) Morphological Operations (MO) 3.2.4.1 Adaptive Histogram Equalization (AHE) Adaptive Histogram Equalization is the method used for the contrast enhancement of images. This is mostly used in gray scale images like medical images where they are in low contrast and they are hence enhanced. The compressed

Chapter 3. Methodology 12 medical images are enhanced again by using this contrast enhancement method as it is simple and effective. It generates mapping for each pixels from the surrounding windows [10].The method is simple and computationally effective that makes it easy to implement and use in real time systems [17]. In this project the medical images from the database that are selected and compressed are given as an input for enhancement. By using the matlab commands and functions the image is enhanced using AHE. Image intensity adjustment is also used in combination with AHE so as to enhance the pixels more clearly. Thus the AHE enhanced output images is obtained for all the lossy and lossless compression techniques. The performance metrics are measured, tabulated and plotted as graphs for a clear understanding of the comparisons made. 3.2.5 Morphological Operations (MO) This technique Morphological Operations (MO) is used in image enhancement of binary images and is also extended to medical images. This is the combination of both erosion and dilation. The images that are compressed are undergone through morphological operations where the background of the image is enhanced efficiently using erosion and dilation. Image background approximation to the background by means of block analysis in conjunction with transformations that enhance images with poor lighting. The multibackground notion is introduced by means of the opening by reconstruction shows a comparison among several techniques to improve contrast in images Thus the desired enhanced outputs are obtained [18]. 3.3 Performance Metrics The performance metrics that are considered for measuring the compression and enhancement techniques of medical images are as follows, Peak Signal to Noise Ratio (PSNR) Mean Square Error (MSE) Structural Similarity Index Modulation (SSIM) 3.3.1 Peak Signal to Noise Ratio (PSNR) PSNR is the method which is selected to measure the comparison between the compression and enhancement techniques. It is the ratio between the maximum

Chapter 3. Methodology 13 possible power of a signal and the power of a corrupting noise. This performance metric is the most commonly used as a measure of quality of reconstruction in image compression and image enhancement. ( ) 255 P SNR = 20 log 10 MSE (3.1) 3.3.2 Mean Square Error (MSE) Mean Square Error (MSE) is another method for comparing the compression and enhancement techniques. This is a criterion for an estimator. MSE minimizes the sum of the squared errors due to bias and variance. The average of the square of the difference between the desired response and the actual system of the output. MSE = 1 MN M y c=1 x r=1 N [I(x r, y c ) I (x r, y c )] 2, (3.2) where I(x r, y c ) and I (x r, y c ) are respectively, the original and the recovered pixel values at the x r row and y c column for the image of size M N. 3.3.3 Structural Similarity Index Modulation (SSIM) Structural similarity Index Modulation is also used to compare the performance of the image compression and enhancement techniques. This is method which is used to measure the similarity between two images. This method is developed to improve the techniques like PSNR and MSE. Here, the input compressed image and the enhanced output image are compared and the structural similarity index value for image I using I as the reference image according to, ( ) ssim(i, I (2µx µ y + C 1 )(2σ x y + C 2 ) ) =, (3.3) (µ 2 x + µ 2 y+ 1 )(σx 2 + σy 2 + C 2 ) where C 1 and C 2 are constant and equal to unity and µ x, µ y, σ x, σ y and σ x y are the local means, standard deviations and cross covariances for the images I,I.

Chapter 4 Results & Analysis To analyze the results three images are selected and then the specific outputs of the respective image are displayed here as results of both compression and enhancement techniques. The images that are considered are named 111.tif, 222.tif and 333.tif respectively. The values obtained from those medical images are also tabulated in a tabular form and displayed accordingly. 4.1 Output Image for 111.tif The Compressed and the Enhanced outputs of this image are displayed one after the other below. Lossy Techniques (a) Original Image (b) DCT out compressed image Figure 4.1.1: Lossy compression of medical image using DCT 14

Chapter 4. Results & Analysis 15 (a) Input Medical Image (b) DWT image after compression Figure 4.1.2: Lossy compression of medical image using DWT (a) AHE Enhancement for DCT Compressed Image (b) MO Enhancement for DCT Compressed Image Figure 4.1.3: Enhancement of DCT compressed image using AHE and MO (a) AHE Enhancement for DWT Compressed Image (b) MO Enhancement for DWT Compressed Image Figure 4.1.4: Enhancement of DWT compressed image using AHE and MO

Chapter 4. Results & Analysis 16 Lossless Techniques (a) BTC Compressed Image (b) RLE Compressed Image Figure 4.1.5: Lossless Compression using BTC and RLE (a) AHE Enhancement for BTC (b) MO Enhancement for BTC Figure 4.1.6: Enhancement of BTC compressed image using AHE and MO

Chapter 4. Results & Analysis 17 (a) AHE Enhancement for RLE (b) MO Enhancement for RLE Figure 4.1.7: Enhancement of RLE compressed image using AHE and MO 4.2 Output Image for 222.tif Lossy Techniques (a) Original Image (b) DCT out compressed image Figure 4.2.1: Lossy compression of medical image using DCT

Chapter 4. Results & Analysis 18 (a) Input Medical Image (b) DWT image after compression Figure 4.2.2: Lossy compression of medical image using DWT (a) AHE Enhancement for DCT Compressed Image (b) MO Enhancement for DCT Compressed Image Figure 4.2.3: Enhancement of DCT compressed image using AHE and MO (a) AHE Enhancement for DWT Compressed Image (b) MO Enhancement for DWT Compressed Image Figure 4.2.4: Enhancement of DWT compressed image using AHE and MO

Chapter 4. Results & Analysis 19 Lossless Techniques (a) BTC Compressed Image (b) RLE Compressed Image Figure 4.2.5: Lossless Compression using BTC and RLE (a) AHE Enhancement for BTC (b) MO Enhancement for BTC Figure 4.2.6: Enhancement of BTC compressed image using AHE and MO

Chapter 4. Results & Analysis 20 (a) AHE Enhancement for RLE (b) MO Enhancement for RLE Figure 4.2.7: Enhancement of RLE compressed image using AHE and MO 4.3 Output Image for 333.tif Lossy Techniques (a) Original Image (b) DCT out compressed image Figure 4.3.1: Lossy compression of medical image using DCT

Chapter 4. Results & Analysis 21 (a) Input Medical Image (b) DWT image after compression Figure 4.3.2: Lossy compression of medical image using DWT (a) AHE Enhancement for DCT Compressed Image (b) MO Enhancement for DCT Compressed Image Figure 4.3.3: Enhancement of DCT compressed image using AHE and MO (a) AHE Enhancement for DWT Compressed Image (b) MO Enhancement for DWT Compressed Image Figure 4.3.4: Enhancement of DWT compressed image using AHE and MO

Chapter 4. Results & Analysis 22 Lossless Techniques (a) BTC Compressed Image (b) RLE Compressed Image Figure 4.3.5: Lossless Compression using BTC and RLE (a) AHE Enhancement for BTC (b) MO Enhancement for BTC Figure 4.3.6: Enhancement of BTC compressed image using AHE and MO

Chapter 4. Results & Analysis 23 (a) AHE Enhancement for RLE (b) MO Enhancement for RLE Figure 4.3.7: Enhancement of RLE compressed image using AHE and MO

Chapter 4. Results & Analysis 24 4.4 Tabular Forms of Performance Parameters 4.4.1 Performance Metrics Tabular Form for 111.tif Performance metrics output image w.r.t input PSNR(dB) MSE SSIM image DCT compressed Image 91.94973426 4.15 10 5 0.986203386 AHE enhancement for 75.37023259 0.00188824 0.963423424 DCT compressed image MO enhancement for 51.64641713 0.445080582 0.050327273 DCT compressed image DWT compressed image 91.96046744 4.14 10 5 0.991260628 AHE enhancement for 75.37304215 0.001887018 0.969275783 DWT compressed image MO enhancement for 51.63273634 0.44648485 0.046785188 DWT compressed image Block truncation compressed 79.57898049 0.000716444 0.899149203 image AHE enhancement for 74.33496402 0.002396536 0.869922574 block truncation image MO enhancement for 51.72625772 0.436972986 0.058670346 block truncation image RLE compressed image 79.50344365 0.000729014 0.90101147 AHE enhancement for 74.44766171 0.002335147 0.87224271 RLE compressed image MO enhancement for 51.72278998 0.437322038 0.058110674 RLE compressed image Table 4.1: Image 111.tif tabular form The performance metrics for image 111.tif are calculated and tabulated for PSNR, MSE and SSIM. For the image 111.tif from the table 4.1 it can be observed MO is the less suitable algorithm to enhance images after compression using lossy and lossless techniques. Comparing PSNR values for MO algorithm that are approximately 51 db with greater values in AHE method in the range [74,80] db shows that MO is less suitable algorithm to enhance images after compression. For this image neither AHE nor MO enhanced the image properly because the PSNR and SSIM values after AHE and MO are lower as compared to PSNR and SSIM values after compression from the table.

Chapter 4. Results & Analysis 25 4.4.2 Performance Metrics Tabular Form for 222.tif Performance metrics Output images w.r.t input PSNR(dB) MSE SSIM image DCT compressed Image 77.05392243 0.00128141 0.92861073 AHE enhancement for 77.2180706 0.001233881 0.933424602 DCT compressed image MO enhancement for 67.89265671 0.010563667 0.837531458 DCT compressed image DWT compressed image 74.30656847 0.002412257 0.467752948 AHE enhancement for 78.91737387 0.00083434 0.926322189 DWT compressed image MO enhancement for 66.26158069 0.015378794 0.837602682 DWT compressed image Block truncation compressed 69.39853893 0.007468381 0.834725941 image AHE enhancement for 70.4017972 0.005927897 0.796081433 block truncation image MO enhancement for 65.03594893 0.020393204 0.746747753 block truncation image RLE compressed image 70.20752191 0.006199093 0.833993808 AHE enhancement for 70.22341105 0.006176455 0.767935478 RLE compressed image MO enhancement for 67.07214746 0.012760439 0.74775475 RLE compressed image Table 4.2: Image 222.tif tabular form Table 4.2 shows the performance metrics values for the image 222.tif. From this table we observe that the image with high PSNR value shows good enhancement. AHE enhancement has better PSNR values than compared to MO enhancement. For this image AHE enhanced the image because PSNR values after AHE are greater (77,78) db as compared to PSNR values after compression which are (70, 72) db. For RLE, AHE doesn t enhance much by seeing the values of PSNR for AHE with RLE before (70.20) db and after enhancement (70.23)dB shows not much improvement in PSNR. In this case of DWT compression AHE enhanced the compressed image significantly comparing the PSNR and SSIM values for AHE with DWT before and after AHE. MO further reduced PSNR s compared to PSNR s directly after compression.

Chapter 4. Results & Analysis 26 4.4.3 Performance Metrics Tabular Form for 333.tif Performance metrics Output images w.r.t input PSNR(dB) MSE SSIM image DCT compressed Image 71.66771337 0.004429034 0.794859736 AHE enhancement for 71.78737069 0.004308671 0.804049513 DCT compressed image MO enhancement for 54.82488614 0.214087715 0.459549559 DCT compressed image DWT compressed image 71.40085115 0.004709722 0.736046619 AHE enhancement for 73.57579609 0.002854307 0.879990114 DWT compressed image MO enhancement for 54.37652594 0.237371059 0.497204429 DWT compressed image Block truncation compressed 62.27506474 0.038510033 0.524254062 image AHE enhancement for 65.37104159 0.018878879 0.513743919 block truncation image MO enhancement for 54.20134883 0.247141386 0.328382448 block truncation image RLE compressed image 64.9894927 0.02061252 0.537570335 AHE enhancement for 64.99433301 0.02058956 0.522739497 RLE compressed image MO enhancement for 54.95144307 0.207939049 0.359419143 RLE compressed image Table 4.3: Image 333.tif tabular form Here, the tabular form is shown for the image 333.tif for PSNR, MSE and SSIM performance metrics. The SSIM values for DCT are greater than the SSIM values for BTC for the images from the values obtained in the table. For this image AHE enhanced the image because PSNR values after AHE are greater as compared to PSNR values after compression. For RLE, AHE doesn t enhance much by seeing the values of PSNR for AHE with RLE before and after. In this case of DWT compression AHE enhanced the compressed image significantly comparing the PSNR and SSIM values for AHE with DWT before (73,74)dB and after AHE (79,80)dB. MO further reduced PSNR s to (65,67)dB compared to PSNR s directly after compression which are (69,70)dB.

Chapter 4. Results & Analysis 27 4.5 Plots for PSNR, MSE and SSIM for the image database In Figure 4.5.1 high value of PSNR indicates good image quality where these values are high for some images in the 100 images database where the peaks are high. In those places we observe good enhanced images after compression as shown in the graph plots below. From this plot it is clearly shown that PSNR values shows significant increase when using DWT compression and after enhancing it with AHE enhancement technique. The PSNR values for MO enhancement are comparatively lower after enhancement thus not showing any improvement in the quality. MO enhancement is least suitable for enhancement of medical images because it gives lower PSNR and SSIM values compared to AHE enhancement.

Chapter 4. Results & Analysis 28 Figure 4.5.1: PSNR plot for all medical images database.

Chapter 4. Results & Analysis 29 Figure 4.5.2: SSIM plot for all medical images database.

Chapter 4. Results & Analysis 30 In Figure 4.5.2 high value of SSIM indicates good image quality where these values are high for some images in the 100 images database where the peaks are high. In those places we observe good enhanced images after compression as shown in the graphs plotted. MO enhancement is least suitable for enhancement of medical images because it gives lower PSNR and SSIM values compared to AHE enhancement. The SSIM values for DCT are greater than the SSIM values for BTC for the images as seen from the plot.

Chapter 5 Conclusion & Future Work The main purpose if this thesis is to analyze the performance parameters and the performance of the different compression and enhancement techniques. A detailed literature review has been done to understand the different characteristics and the working of these techniques. From this literature research, a clear knowledge has been obtained on the compression and enhancement techniques and how they work on medical gray scale images. Firstly, the compression is performed using both lossy and lossless techniques and then followed by enhancing them. DCT, DWT, RLE and BTC are used for compression. DWT lossy compression gives better results than DCT when enhanced based on PSNR, MSE and SSIM without losing more information. RLE and BTC are compress well without loosing much data. RLE shows good compression rate than BTC from the analysis. Each compression technique is further enhanced using AHE and MO techniques.here, we observe the combinations of the compression and enhancement techniques that worked well together. RLE has good values and better quality of images after enhancement rather than BTC by comparing the PSNR and SSIM values.the combination of AHE and RLE gives better enhancement results compared to any other techniques. In the case of DWT compression AHE enhanced the compressed image significantly comparing the PSNR and SSIM values for AHE with DWT before and after AHE. Morphological operations are used to enhance the background rather than the sharpening or increasing the image contrast. this technique in specific is used to enhance the particular region of interest as seen in the results. There is always a need to explore new methods to find an effective solution. In future, people may also use genetic algorithms and edge detection techniques and can compare these techniques by using different parameters. 31

References [1] D. Meenakshi and V. K. Devi, Literature review of image compression technique, International Journal of Computer Science & Engineering Technology, vol. 1, no. 6, pp. 286 288. [2] S. S. ME, V. Vijayakuymar, and R. Anuja, A survey on various compression methods for medical images, International Journal of Intelligent Systems and Applications, vol. 4, no. 3, p. 13, 2012. [3] S. Bedi and R. Khandelwal, Various image enhancement techniques-a critical review, International Journal of Advanced Research in Computer and Communication Engineering, vol. 2, no. 3, 2013. [4] K. Cabeen and P. Gent, Image compression and the discrete cosine transform, College of the Redwoods, 1998. [5] A. S. Lewis and G. Knowles, Image compression using the 2-d wavelet transform, IEEE transactions on image processing, vol. 1, no. 2, pp. 244 250, 1992. [6] M. M. H. Chowdhury and A. Khatun, Image compression using discrete wavelet transform, IJCSI International Journal of Computer Science Issues, vol. 9, no. 4, pp. 327 330, 2012. [7] S. Benchikh and M. Corinthios, A hybrid image compression technique based on dwt and dct transforms, 2011. [8] A. M. A. Ibrahim and M. E. Mustafa, Comparison between (rle and huffman) algorithmsfor lossless data compression, IJITR, vol. 3, no. 1, pp. 1808 1812, 2015. [9] E. Delp and O. Mitchell, Image compression using block truncation coding, IEEE transactions on Communications, vol. 27, no. 9, pp. 1335 1342, 1979. [10] T. Arici, S. Dikbas, and Y. Altunbasak, A histogram modification framework and its application for image contrast enhancement, IEEE Transactions on image processing, vol. 18, no. 9, pp. 1921 1935, 2009. 32

References 33 [11] P. Maragos, Morphological filtering for image enhancement and feature detection, analysis, vol. 19, p. 18, 2005. [12] A. B. Watson, Image compression using the discrete cosine transform, Mathematica journal, vol. 4, no. 1, p. 81, 1994. [13] N. Saroya and P. Kaur, Analysis of image compression algorithm using dct and dwt transforms, International Journal of Advanced Research in Computer Science and Software Engineering, vol. 4, no. 2, 2014. [14] M. Kamel, C. Sun, and L. Guan, Image compression by variable block truncation coding with optimal threshold, IEEE Transactions on Signal Processing, vol. 39, no. 1, pp. 208 212, 1991. [15] D. Halverson, N. Griswold, and G. Wise, A generalized block truncation coding algorithm for image compression, IEEE transactions on acoustics, speech, and signal processing, vol. 32, no. 3, pp. 664 668, 1984. [16] R. Maini and H. Aggarwal, A comprehensive review of image enhancement techniques, arxiv preprint arxiv:1003.4053, 2010. [17] M. Abdullah-Al-Wadud, M. H. Kabir, M. A. A. Dewan, and O. Chae, A dynamic histogram equalization for image contrast enhancement, IEEE Transactions on Consumer Electronics, vol. 53, no. 2, 2007. [18] K. Sreedhar and B. Panlal, Enhancement of images using morphological transformation, arxiv preprint arxiv:1203.2514, 2012.