图像缩放算法比较分析(IJIGSP-V5-N5-7)
基于改进自组织映射和BP神经网络的高速图像压缩.(IJIGSP-V6-N5-4)
High-speed Image compression based on the Combination of Modified Self-organizing Maps and Back-Propagation Neural Networks
Omid Nali Department of Electrical Engineering, Saghez branch, Islamic Azad university, Saghez, Iran E-mail: omid.nali@ Abstract — This paper presents a high speed image compression based on the combination of modified selforganizing maps and Back-Propagation neural networks. In the self-organizing model number of the neurons are in a flat topology. These neurons in interaction formed selforganizing neural network. The task this neural network is estimated a distribute function. Finally network disperses cells in the input space until estimated probability density of inputs. Distribute of neurons in input space probability is an information compression. So in the proposed method first by Modified SelfOrganizing Feature Maps (MSOFM) we achieved distributed function of the input image by a weight vector then in the next stage these information compressed are applied to back-propagation algorithm until image again compressed. The performance of the proposed method has been evaluated using some standard images. The results demonstrate that the proposed method has Highspeed over other existing works. Index Terms — Image compression; Back-Propagation algorithm; Modified Self-Organizing Feature Maps. I. INTRODUCTION 2- Hebbian learning based image compression 3- Vector Quantization (VQ) neural networks. 4- Predictive neural networks. In this paper the proposed method is based on two major stages, the first stage is MSOFM and the second stage is back-propagation algorithm. In the first stage by MSOFM and the proposed weight update method estimated a distribute function of the input image in lower dimensions by neurons (weight matrix) this is first data compression. In second stage weight matrix is applied to back-propagation algorithm until another stage of compression is applied to the input image. Figure 1 shows a block diagram of the proposed method.
评估及比较视频压缩运动估计算法(IJIGSP-V5-N10-2)
I.J. Image, Graphics and Signal Processing, 2013, 10, 9-18Published Online August 2013 in MECS (/)DOI: 10.5815/ijigsp.2013.10.02Evaluation and Comparison of Motion Estimation Algorithms for Video CompressionAvinash Nayak and Bijayinee BiswalAjay Binay Institute of Technology, Odisha, Indianayak.av@S. K. SabutM.S. Ramaiah Institute of Technology, Bangalore, Indiasukanta207@Abstract — Video compression has become an essential component of broadcast and entertainment media. Motion Estimation and compensation techniques, which can eliminate temporal redundancy between adjacent frames effectively, have been widely applied to popular video compression coding standards such as MPEG-2, MPEG-4. Traditional fast block matching algorithms are easily trapped into the local minima resulting in degradation on video quality to some extent after decoding. In thi s paper various computing techniques are evaluated in video compression for achieving global optimal solution for motion estimation. Zero motion prejudgment is implemented for finding static macro blocks (MB) which do not need to perform remaining search thus reduces the computational cost. Adaptive Rood Pattern Search (ARPS) motion estimation algorithm is also adapted to reduce the motion vector overhead in frame prediction. The simulation results showed that the ARPS algorithm is very effective in reducing the computations overhead and achieves very good Peak Signal to Noise Ratio (PSNR) values. This method significantly reduces the computational complexity involved in the frame prediction and also least prediction error in all video sequences. Thus ARPS technique is more efficient than the conventional searching algorithms in video compression.Index Terms— Video Compression, Motion Estimation, Full Search Algorithm, Adaptive, Rood Pattern Search, Peak Signal to Noise RatioI.I NTR ODUC TIONImportance of digital video coding has increased significantly since the 90s when MPEG-1 first came to the picture. Compared to analog video, video coding achieves higher data compression rates without significant loss of subjective picture quality which eliminates the need of high bandwidth as required in analog video delivery to a large extent. Digital video is immune to noise, easier to transmit and is able to providea more interactive interface to the users [1]. The specialized nature of video applications has led to the development of video processing systems having different size, quality, performance, power consumption and cost.A major problem in a video sequence is the high requirement of memory space for storage. A typical system needs to send dozens of individual frames per second to create an illusion of a moving picture. For this reason, several standards for compression of the video have been developed. Each individual frame is coded to remove the redundancy [2]. Furthermore, between consecutive frames, a great deal of redundancy is removed with a motion compensating system. Motion estimation and compensation are used to reduce temporal redundancy between successive frames in the time domain.A number of fast block matching motion estimation algorithms were considered in different video coding standards because massive computation were required in the implementation of exhaustive search (ES). In order to speed up the process by reducing the number of search locations, many fast algorithms have been developed, such as the existing three-step search (TSS) algorithm [3]. The Three Step Search method is based on the real world image sequence’s characteristic of centre-biased motion vector distribution, and uses centre-biased checking point patterns and a relatively s mall number of search locations to perform fast block matching. In order to reduce the computational complexity for motion estimation and improve the reliability of the image sequences for super-resolution reconstruction, an effective three-step search algorithm is presented. Based on the center-biased characteristic and parallel processing of the motion vector, the new algorithm adopts the multi-step search strategy [4].A simple, robust and efficient fast block-matching motion estimation (BMME) algorithm called diamond search, which employs two search patterns. The first pattern, called large diamond search pattern (LDSP), comprises nine checking points from which eight points surround the center one to compose a diamond shape. The second pattern consisting of five checking points forms a smaller diamond shape, called s mall diamond search pattern (SDSP).10Evaluation and Comparison of Motion Estimation Algorithms for Video CompressionA simple fast block-matching algorithm (BMA), called adaptive rood pattern searches (ARPS), which consist of two sequential search stages: 1) initial search and 2) refined local search. The initial search is performed only once at the beginning for each MB. This removes unnecessary intermediate search. For the initial search stage, ARP is proposed, based on the available motion vectors (MVs) of the neighboring MBs. In the next stage, a unit-size rood pattern (URP) is exploited repeatedly, and unrestrictedly, until the final MV is found. In this paper we have evaluated the following four algorithms: Exhaustive Search (ES), Three Step Search (TSS), Diamond Search (DS), and ARPS.II.METHODSIn a conventional predictive coding [5-6], the difference between the current frame and the predicted frame is encoded. The prediction is done using any of the BMA. BMA are used to estimate the motion vectors. Block-matching consumes a significant portion of time in the encoding step.A.Block matching algorithmBlock matching algorithm (BMA) is widely used in many motion-compensated video coding systems such as H.261 and MPEG standards to remove interframe redundancy and thus achieve high data compression [7, 8]. The process of block-matching algorithm is illustrated in Fig.1. Motion estimation is performed on the luminance block in which the present frame is matched against candidate blocks in a search area on the reference frame for coding efficiency. The best candidate block is found and its motion vector is recorded. Typically the input frame is subtracted from the prediction of the reference frame, thus interframe redundancy is removed and data compression is achieved. At receiver end, the decoder builds the frame difference signal from the received data and adds it to the reconstructed reference frames. This algorithm is based on a translational model of the motion of objects between frames [9].Reference Frame Current FrameFigure 1. Block-matching motion estimationThe block-based motion vectors can be estimated by using block matching, which minimizes a measure of matching error. The destination of motion estimation is to find macro-block (MB) in the reference frame which has the smallest difference from the MB in the current frame. The difference is denoted by Sum of Absolute Difference (SAD), as shown in equation (1). The SAD is the most popular matching criteria used for block-based motion estimation.1100(,)(,)(,),,N Ni jS A D m n c i j s i m j n m nωω−−===−++≤≤∑∑ (1)Where SAD (m, n) is the distortion of the candidate block at search position (m, n), {c (x, y) | 0 ≤ x ≤ N −1, 0≤ y ≤ N −1} means current block data, {s (x, y)| −w ≤ x ≤ w + N −1,−w ≤ y ≤ w + N −1} stands for search area data, the search range is [-w, w], the block size is N×N. (2w+1) 2 motion vectors to be checked .Consider a block of pixels of size N × N in the reference frame, at a displacement of, where I and j are integers with respect to the candidate block position. SAD makes the error values as positive, but instead of summing up the squared differences, the absolute differences are summed up. The SAD criterion shown in equation (1) requires N2computations of subtractions with absolute values and additions N2 for each candidate block at each search position. The absence of multiplications makes this criterion computationally more attractive and facilitates easier hardware implementation. Peak-Signal-to-Noise-Ratio (PSNR) given by equation (2) characterizes the motion compensated image that is created by using motion vectors and macro blocks from the reference frame.Γ=Round |MV������⃗predicted|= Round(y)]MV(x)[MV predicted2predicted2+(2) Where MV predicted(x)and MV predicted(y) are the horizontal and vertical components of the predicted MV, respectively. Operator “Round” performs rounding operation, which takes the nearest integer value of the argument.B.Exhaustive search (ES) algorithmThe exhaustive search (ES) algorithm also known as Full Search is the most computationally expensive block matching algorithm. This algorithm calculates the cost function at each possible location in the search window. It gives the highest PSNR amongst any block matching algorithm by the best possible match [10]. Fast block matching algorithms try to achieve the same PSNR doing as little computation as possible. The obvious disadvantage to ES is that the larger the search window gets the more computations it requires.Search window (2w×2w)Reference frame Candidate frameFigure 2. Exhaustive Search Motion EstimationConsider a block of N × N pixels from the candidates frame at the coordinate position (r, s) as shown in Fig.2 above and then consider a search window having a range ±w in both the directions in the references frame, as shown. For each of the (2w + 1)2search position (including the current row and the current column of the reference frame), the candidate block is compared with a block of size N × N pixels, according to one of the matching criteria and the best matching block, along with the motion vector is determined only after all the (2w+1)2 search position are exhaustively explored. However, it is highly computational intensive.C.Three step search (TSS) algorithmKoga et al introduced this algorithm [11]. It became very popular because of its simplicity and also robust and near optimal performance. It searches for the best motion vectors in a coarse to fine search pattern. The algorithm has steps as described with the help of Fig.3.Step 1: An initial step size is picked. Eight blocks at a distance of step size from the centre are picked for comparison.Step 2: The step size is halved. The centre is moved to the point with the minimum distortion.Figure 3. Three Step Search proceduresThe point which gives the smallest criterion value among all tested points is selected as the final motion vector m.TSS reduces radically the number of candidate vectors to test, but the amount of computation required for evaluating the matching criterion value for each vector stays the same. TSS may not find the global minimum (or maximum) of the matching criterion; instead it may find only a local minimum and this reduces the quality of the motion compensation system. On the other hand, most criteria can be easily used with TSS [12].D.Diamond search (DS) algorithmBy exhaustively testing on all the candidate blocks, full search (FS) algorithm gives the global minimum SAD position which corresponds to the best matching block at the expense of highly computation. To overcome this defect, many fast block matching algorithms (BMAs) are developed such as diamond search [13].The proposed DS algorithm employs two search patterns as illustrated in Fig. 4.1 (a), (b) which are derived from the crosses (×) in Fig. 4. The first pattern, called large diamond search pattern (LDSP), comprises nine checking points from which eight points surround the centre one to compose a diamond shape (◊). The second pattern consisting of five checking points forms a smaller diamond shape, called small diamond search pattern (SDSP) [14,15]. The 13 crosses show all possible checking points within the circle.Figure 4. An appropriate search pattern support-circular areawith a radius of 2 pels. The 13 crosses show all possiblechecking points within the circle.(a) Large Diamond Search Pattern (b) Small Diamond SearchPatternFigure 4.1. Two search patterns derived from the last figure are employed in the proposed DS algorithm.Among the five checking points in SDSP, the position yielding the MBD provides the motion vector of the best matching block [16]. The DS algorithm is performed as follows:Step 1: The initial LDSP is centred at the origin of the search window, and the 9 checking points of LDSP are tested. If the MBD point calculated is located at the centred position, go to Step 3; otherwise, go to Step 2. Step 2: The MBD point found in the previous search step is re-positioned as the centre point to form a new LDSP. If the new MBD point obtained is located at the centre position, go toStep 3; otherwise, recursively repeat this step.Step 4: Switch the search pattern from LDSP to SDSP. The MBD point found in this step is the final solution of the motion vector which points to the best matching block.E.Adaptive rood pattern search (ARPS) algorithmAs we have observed, a small search pattern made up by compactly spaced search points is more suitable than a large search pattern containing sparsely spaced search points in detecting small motions, because only a small number of positions around the search window center arenecessary to be checked [17]. The speed and accuracy ofpattern-based search algorithms intimately depend on the size of the search pattern and the magnitude of the target MV. Therefore, it is highly desirable to use different search patterns according to the estimated motion behavior for the current block. This boils down to two issues required to be addressed: 1) How to pre-determine the motion behavior of the current block for performing efficient ME? 2) What are the most suitable size and shape of the search pattern(s)?Regarding the first issue, the current block’s motion behavior can be predicted by referring to its neighboring blocks’ MVs in the spatial domain. For the second issue, two types of search patterns are used. One is the adaptive rood pattern (ARP) with adjustable rood arm which is dynamically determined for each MB according to its predicted motion behavior. Note that ARP will be exploited only once at the beginning of each MB search [18]. Getting a good starting point for the remaining local search alleviates unnecessary intermediate search and reduces the risk of being trapped into local minimum in the case of long search path. A small, compact, and fixed-size search pattern would be able to complete the remaining local search quickly.1)Prediction of the target MVIn order to obtain an accurate MV prediction of the current block, two factors need to be considered: 1) Choice of the region of support (ROS) that consists of the neighboring blocks whose MVs will be used to calculate the predicted MV, and 2) A lgorithm used for computing the predicted MV.The spatial ROS is limited to the neighboring block(s) with four promising scenarios as shown in Fig.5. Type A covers all the four neighboring blocks, and +type B is the prediction ROS adopted in some international standards such as H.263 for differential coding of MVs. Type C is composed of two directly adjacent blocks, and type D has only one block that situates at the immediate left to the current block. Calculating the statistical average of MVs in the ROS is a common practice to obtain the predicted MV. The mean and median prediction has been tested in our experiments. Others (such as the weighted average) are either too complex in computation or involving undetermined parameters, they are therefore not considered in our work. Extensive experiments are performed with all four types of ROS and two types of prediction criteria- mean and median. Our experimental results show that these ROSs and prediction criteria yield fairly similar performance in terms of PSNR and the total number of checking points required. Therefore, we adopt the simplest ROS (i.e., type D) in our method, which has the least memory requirement, because only one neighboring MV needs to be recorded.TYPE A TYPE B TYPE C TYPE D Figure 5. Four types of ROS, depicted by the shaded blocks.The block marked by “○” is the current block. 2)2) Selection of search patternsAdaptive Pattern -For the Initial Search: The shape of our rood pattern is symmetrical, with four search points locating at the four vertices, as depicted in Fig.5. The main structure of ARP has a rood shape, and its size refers to the distance between any vertex point and the center point. The choice of the rood shape is first based on the observation of the motion feature of real-world video sequences. The rood shape pattern includes all the horizontal and vertical directions, so it can quickly detect such motion, and the searches will directly – ‘jump” into the local region of the global minimum.Secondly, any MV can be decomposed into one vertical MV component and one horizontal MV component. For a moving object which may introduce MV in any direction, rood-shaped pattern can at least detect the major trend of the moving object, which is the desired outcome in the initial search stage. Furthermore, ARP’s symmetry in shape not only benefits hardware implementation, but also increases robustness. It shows that even if the predicted MV could be inaccurate and its magnitude does not match the true motion very well, the rood-shaped pattern which takes all horizontal and vertical directions into consideration can still track the major direction and favor the follow-up refinement process. In addition to the four-armed rood pattern, it is desirable to add the predicted MV into our ARP because it is very likely to be similar to our target MV as shown in Fig.6. By doing so, the probability of detecting the accurate motion in the initial stage will be increased.Figure 6. Adaptive rood pattern (ARP)In our method, the four arms of the rood pattern are of equal length. The initial idea in deciding the ARP’s size is to make it equal to the length of the predicted MV (i.e., the MV of the immediate left block of the current block). That is, the size of ARP, Γ, isΓ=Round |MV������⃗predicted|= Round(y)]MV(x)[MV predicted2predicted2+(3) where MV predicted(x)and MV predicted(y) are the horizontal and vertical components of the predicted MV, respectively. Operator “Round” performs rounding operation, which takes the nearest integer value of the argument.Note that parameter Γ def ined in (2) involves square and square-root operations; thus, increasing difficulty on hardware implementation. Instead, we use only one of the two components of the predicted MV that has the larger absolute value (or magnitude) to determine the size of our ARP.That is:Γ=Max {MV predicted(x),MV predicted(y)} (4)From the mathematical standpoint, [19] the magnitude of MV’s component with larger absolute value is fairly close to the length of MV, and thus Equation (4) is a good approximation of measurement about motion magnitude. Experimental results show that the second definition of Γ using (4) is, in fact, slightly superior to the first one using (3) in terms of higher PSNR and less total number of checking points.The second method equation (4) for the rest of ARPS development was adopted. We observed that the chosen ROS (type D) is not applicable to all the leftmost blocks in each frame. For those blocks, we do not utilize any neighboring MVs, but adopted a fixed-size arm length of 2 pixels for the ARP, since this size agrees to that of LDSP which has fairly robust performance as reported in. Also, longer arm lengths are not considered because the boundary MBs in a frame usually belongs to static background.3)Fixed pattern-for refined local searchIn the initial search using ARP as described earlier, the adaptive rood pattern leads the new search center directly to the most promising area which is around the global minimum; thus, effectively reducing unnecessary intermediate searches along the search path. We use a fixed, compact and small search pattern to perform local refined search unrestrictedly for [MV (x) MV (y)] predicted identifying the global minimum. When a fixed pattern is used, the matching motion estimation (MME) point found in the current step will be re-positioned as the new search center of the next search iteration until the MME point is incurred at the center of the fixed pattern. Two types of most compact search patterns have been investigated in our experiments. One is the five-point unit-size rood pattern which is the same as SDSP used in DS, and the other is a 3x3 square pattern as shown in Fig.7 (a, b). This demonstrates the efficiency of using URP in local motion detection, and it is therefore adopted in our proposed method [20].(a) (b)Figure 7. Two fixed search patterns under consideration Image segmentation i s generally defined as the basic image processing that subdivides a digital image ),(yxfinto its continuous, di sconnect and nonempty subsetnffff,,,321, which provides convenience to extraction of attribute[3]. In general, Image segmentation algorithms are based on two basic principles[4]: the trait of pixels and the information in nearby regions. Most of segmentation algorithms are based on two characters of pixels gray level: discontinuity around edges and similarity in the same region. As is shown in Table I, there are three main categories in image segmentation[5]: A. edge-based segmentation; B. region-based segmentation; C. special- theory-based segmentation. And some sub-classes are included in the main categories too.III.S IMULATION R ESULTS AND D ISCUSSIONIn this paper we have evaluated the concepts of motion estimation, video compression, BMA using Exhaustive Search, Three-step Search, Diamond search and ARPS algorithm for 16 × 16 block size images of Chemical Plant, Toy Vehicle and Walter Cronkite. In ME, the search process can be modified to suit the needs of a particular algorithm. The search area is typically restricted to lower the computational cost associated with block matching. In most of the video sequences, the objects in the scene do not have large translational movements between a frame and the next. That is, the fact that frames in a video sequence are taken at small intervals of time and exploited. A ll tested video scenes are used to generate the frame by frame motion vectors. A.Exhaustive searchFigure 8 shows the simulation results of ES algorithm for a chemical plant where the number of searches throughout the sequence remains the same and the performance of PSNR is higher.Figure 8. a) Frame based number of searches b) Frame based PSNR performance of ES inChemical Plant.B.Three step searchFigure 9 shows the simulation results of TSS algorithm for a chemical plant where the number of searches throughout the sequence varies and the performance of PSNR is lower than ES.Figure 9. a) Frame based number of searches b) Frame based PSNR performance of TSS in Chemical plantC.Diamond searchFigure 10 shows the simulation results of DS algorithm for a chemical plant where the number of searches is less than ES and TSS but the performance of PSNR is lower than TSS.Figure 10. a) Frame based number of searches b) Frame based PSNRof DS in Chemical plantD.Adaptive rood pattern searchFigure11 shows the simulation results of ARPS algorithm for a chemical plant where the number of searches is less than ES, TSS , DS and the performanceof PSNR is higher than TSS, DS and comparable to ES.Figure 11. a) Frame based number of searches b) Frame based PSNR of ARPSparison of algorithmsNumber of search points per macro-block obtained for various frames of chemical plant video sequences is depicted in Fig.12 and Fig. 13 shows PSNR value with respect to corresponding frame for various algorithms.Figure 12. No. of frames versus search points per macroblock for video sequences Figure 13. No. of frames versus PSNR for various methods for chemical plantF. Motion compensated image comparisonThe motion compensated images, obtained by using DS, TSS, A RPS and ES algorithm based on number of search points is shown in Fig.14. The images for different algorithms differ in picture clarity. A RPS and ES yield the best motion compensated images but ARPS does it more efficiently, since the number of searches permacroblock is very less as compared to ES.Figure 14. Comparison of the performance of DS, TSS, ARPS and ESG. Comparison of the Performance of AlgorithmsThe performances of various algorithms based on number of searches and PSNR values for video compression are compared and the results are presented in Table 1 and Table 2.The simulated results showed that, out of the four algorithms, the values for the average number of searches, for ARPS, were 10.5757, 7.735 and 10.664, similarly for DS, the values were 20.7326, 15.9175 and 18.1875, for ES were 199.5116, 212.0664 and 199.5156, for TSS were 23.4384, 23.9713 and 23.0717 for chemical plant, toy vehicle and Walter Cronkite respectively.It proved that though ES algorithm finds the best match between the block of the current frame but searches all possible positions thereby making it computationally more expensive. Still this algorithm is considered optimal because it is capable of generating improved motion vectors, because of a high PSNR value, resulting in better quality of videos, where as the ARPS searches the least number of search points for MV generation, less than TSS and DS. Very good picture quality can be achieved using ARPS with very few numbers of searches using ARPS. Similarly the PSNR results for ES yielded values of 24.0595, 27.6936 and 35.1491, for DS were 23.3651, 27.5863 and 34.5904, for TSS were 23.5551, 27.629 and 34.5217, and for ARPS were 23.7884, 27.5995 and 34.5904 for chemical plant, toy vehicle and Walter Cronkite respectively.The evaluated result shows that the PSNR values are somewhat similar in all the four algorithms. The ES scores are more over the rest algorithms, closely followed by ARPS, suggesting that ARPS maintains similar PSNR performance of ES in most sequences and achieves a superior PSNR than DS and TSS. Exhaustive Search algorithm finds the best match between the block of the current frame and all possible positions inside the search are set in the reference frame. Though this algorithm is computationally more expensive than other proposed algorithms, still this algorithm is considered optimal because it is capable of generating improved motion vectors, with a high PSNR value, resulting in better quality of videos.TABLE 1. AVERAGE NUMBER OF SEARCH POINTSFOR ARPS, DS, ES AND TSTABLE 2. AVERAGE PSNR FOR ARPS, DS, ES AND TSThe tradeoff between performance, simplicity and the fact that the improvement resulted from the adaptabilityof our search pattern, and more importantly, avoiding local minimum matching error points. This is done by tracking the major trend of the motion at the initial stage, since complex motions and unevenness of the objects cause large number of local minimums on the matching error surface, checking points in all directions (as being done by Large Diamond Search Pattern of Diamond Search Algorithm) at the initial step increases the risk of being trapped into the local minima and thus degrades the search accuracy. Thus we conclude that ARPS is the best block matching algorithm for video compression using motion estimation.R EFERENCES[1] Tekalp A. Digital video processing, Prentice Hall,PTR, 1995.[2] Richardson I.G. H.264 and MPEG-4 videocompression. Wiley, Chichester, England, 2003.[3] Jain J. and Jain, A. Displacement Measurement andits Application in Interframe Image Coding. IEEETrans on Communication, COM- 29, 1981: 1799-1808.[4] Ning-ning, S., Chao, F., Xu, X. An Effective Three-step Search Algorithm for Motion Estimation. IEEEInt Symposium on IT in Medicine & Education,2009:400- 403.[5] Netravali A.N. and Robbins J.D. Motioncompensated television coding: Part I.‖Journal ofBell Syst Technical, 1979, 58: 631-670.[6] Lin Y.C. and Tai S.C. Fast Full-Search Block-Matching Algorithm for Motion- CompensatedVideo Compression. IEEE Trans on Communications, 1997, 45(5): 527-531.[7] CCITT SG XV. Recommendation H.261-Video codecfor audiovisual services at p*64 kbits/s. Tech. Rep.COM XV-R37-E, 1990.[8] MPEG ISO CD 11172-2: Coding of moving picturesand associated audio for digital storage media at upto about 1.5 M bits/s, 1991.[9] Kappagantula S. and Rao K.R. Motion compensatedinterframe image Prediction. IEEE Trans Commun.COM, 1985, 33: 1011-l015.[10] Ahmed Z., Hussain, A. J. and Al-Jumeily D. FastComputations of Full Search Block MatchingMotion Estimation (FCFS). IEEE Trans onCommunications, 2011: 1-6.[11] Reoxiang L., Bing Z. and Liou M.L. A new three-step search algorithm for block motion estimation.IEEE Trans on Circuits and Systems for VideoTechnology,1994, 4: 438-442.[12] Barjatya A. Block Matching Algorithms for MotionEstimation. DIP 6620 Final Project Paper, 2004.[13] Cheung C.H and Po L.M. A novel cross-diamondsearch algorithm for fast block motion estimation. IEEE Trans Circuits Syst Video Technol, 2002, 12: 1168- 1177.[14] Zhu S. and Ma K.K. A new diamond searchalgorithm for fast block-matching motion estimation.Proc Int Conf Information Communications and Signal Processing (ICICS), 1997, 9(1): 292–296. [15] Zhu S. Fast motion estimation algorithms for videocoding. M.S. thesis, School Elect Electron Eng,Nanyang Technol Univ, Singapore, 1998.[16] Zhu S. and Ma K.K. A New Diamond SearchAlgorithm for Fast Block Matching Motion Estimation. IEEE Trans on Image Processing, 2000,9(2): 287-290.[17] Shen J.F., Chen L.G., Chang H.C., Wang T.C. Lowpower full-search block matching motion estimationchip for H.263+. IEEE International Symposium onCircuits and Systems, 1999, 4:299-302.[18] Nie Y. and Ma K.K. (2002). Adaptive rood patternsearch for fast block-matching motion estimation.IEEE Trans Image Processing, 2002, 11 :1442-1448. [19] Kaushik M. Comparative Analysis of ExhaustiveSearch Algorithm with ARPS A lgorithm for MotionEstimation. International Journal of Applied Information Systems (IJAIS), 2012: 1(6), 16-19. [20] Kiran S.V., Prasad K.V., Lalitha N.V. and Rao D.S.Architecture for the ARPS Algorithm. InternationalJournal of Advances in Computer Networks and itsSecurity, 2002: 443-448.Nayak A. w as born in Cuttack, Orissa, India on June 20th 1981. Nayak is now working as lecturer in the Department of Electronics and Telecommunication, Ajay Binay Institute of Technology, Cuttack. He received his B.E. degree in Electronics & TeleCommunication in 2003 from CVRCE, M. Tech in Electronics & TeleCommunication from KIIT University, India in 2012. He has over 8 years of experience in teaching and research in Electronics & Communication engineering. His research interest includes signal and image processing. He is a member of ISTE(INDIA).Biswal B. w as born in Keonjhar, Orissa, India on November 10th 1985. Biswal is now working as lecturer in the Department of Electronics and Telecommunication, Ajay Binay Institute of Technology, Cuttack. She received her B. Tech degree in Electronics &Telecommunication Engineering in 2007 from ABIT, M. Tech in Electronics and Communication Engineering from IIT, Kharagpur, India in 2013. She has 6 years of experience in teaching and research in the field of Electronics & Communication engineering. Her research interest includes communication, signal and image processing. She is a member of Orissa Information Technology Society and ISTE, India.。
多相图像分类的变异水平集方法研究(IJIGSP-V3-N5-8)
I.J. Image, Graphics and Signal Processing, 2011, 5, 51-57Published Online August 2011 in MECS (/)Variation Level Set Method for MultiphaseImage ClassificationZhong-Wei Li, Ming-Jiu NiCollege of Physics ScienceGraduate University of Chinese Academy of ScienceBeijing, ChinaEmail: qdlzw39@Zhen-Kuan PanCollege of Information Engineering, Qingdao UniversityQingdao, Shandong, ChinaAbstract—In this paper a multiphase image classification model based on variation level set method is presented. In recent years many classification algorithms based on level set method have been proposed for image classification. However, all of them have defects to some degree, such as parameters estimation and re-initialization of level set functions. To solve this problem, a new model including parameters estimation capability is proposed. Even for noise images the parameters needn’t to be predefined. This model also includes a new term that forces the level set function to be close to a signed distance function. In addition, a boundary alignment term is also included in this model that is used for segmentation of thin structures. Finally the proposed model has been applied to both synthetic and real images with promising results.Index Terms—partial differential equations, level set, image classification, boundary alignment, re-initializationI.I NTRODUCTIONThe objective of this work is image classification that is a basic problem in image processing. Although this task is usually easy and natural for human beings, it is difficult for computers. Image classification is considered as assigning a label to each pixel of an image. A set of pixels with the same label represent a class. The purpose of classification is to get a partition compound of homogeneous regions. The feature criterion is the spatial distribution of intensity. Stochastic approach was first proposed in [1]. Later a supervised variational classification model based on Cahn-Hilliard models was introduced in [2]. During recent years many classification models have been developed to improve the quality of image classification([3], [4], [5], [6]).Osher and Sethian [7] proposed an effective implicit representation called level set for evolving curves and surfaces, which allows for automatic change of topology, such as merging and breaking. A supervised mode based on level set and region growing method was developed in [8]. However, this model doesn’t include the estimation for the intensity values of each region and level set function needs to be re-initialized. To solve these problems, an unsupervised model is proposed in this paper. Li [9] firstly introduced a level set evolution without re-initialization. In this paper a similar term is introduced to improve our model. The new term can force the level set function to be close to a signed distance function.In the classification process the information is often neglected that is the orientation of the image gradients. The gradient magnitude edge indicator is not enough for capturing thin structures. Vasilevskiy and Siddiqi used maximization of the inner product between a vector field and the surface normal in order to construct an evolution that is used for segmentation of thin structures [10]. This term is a reliable edge indicator for relatively low noise levels. In the case, high noise levels, additional regularization techniques are required.The resulting of the proposed model is a set of Partial Differential Equations. These equations govern the evolution of the interfaces to a regularized partition. The evolution of each interface is guided by forces which include internal force based on regularization term, external force based on region partition term and boundary alignment term. The term of re-initialization is used to penalize the deviation of the level set function from a signed distance function.This paper is organized as follows. First, the problem of classification is stated as a partition problem. Then Set the framework and define the properties about classification. Second, an unsupervised classification model based on level set evolution is proposed through a level set formulation. The Euler-Lagrange derivative of the model leads to a dynamical equation. Finally, some experiment with promising results are presented.II.IMAGE CLASSIFICATION FRAMEWORKSIn this section the properties which the classification model needs to satisfy with are presented. The classification of the problem is considered as a partition problem. Each partition is compound of homogeneousregions separated by interfaces. Herein, suppose that each class has a homogeneous distribution of intensify (or greylevel). Therefore each class is characterized by its mean value of grey level. However, the intensity values of each region are unknown and should be estimated before classification. In next section the estimation method ofintensity values will be discussed in detail. In order to complete classification some feature criterions shouldbeen defined.Let Ω be an open domain subset of 2R , with ∂Ωits boundary. Let C be a closed subset in Ω, made up of afinite set of smooth curves. The connected components of CΩ are denoted by Ω, such that . Letrepresents the image intensity. Eachregion in the image is characterized by its meanintensity (). The number K of total phases is supposed to be given from a previous estimation. And let be the region defined as i ki i ΩC U Ω=U Ω→u 0:u i Ωi R =1,2,i 3....{}Ω=∈Ω∈.x x u i i (2) A partitioning which penalizes overlapping and theformation of vacuum is considered to find a set {}, whereΩ=1......i i k Ω=ΩΩΩ=∅=≠U I .1kandi i j i i j(3)In the next section the solution of classification model has to take into account these conditions.III.MULTIPHASE CLASSIFICATION MODELThe unsupervised model in this paper is inspired by the work ([7], [8], [9]). In this paper we use a level set formulation to represent each interface and region. In this paper we use a level set formulation to represent each interface and region. A. Preliminaries Let:i R Rφ+Ω×→i Ω be a Lipschitz functionassociated to region()()()φφφ⎧>∈Ω⎪⎪⎪=∈∂Ω⎪⎨⎪⎪<∈⎪⎪⎩,0,0.,0i i ii x t if x x t if x Thus the function (),i x t φis used to describe theregion i Ω and i ∂Ω represents the boundary of iΩ. Inthe following, we will sometimes omit spatial parameterx and time parameter in (),i x t φ. B. Parameters EstimationIn order to complete partition region, the estimation for the intensity values of each region in and insure the computation of a global minimum, let we define theapproximations αH and αδof Heaviside and Diracfunctions, as shown in Fig 1(a) and Fig 1(b).()()22121arctan 21.H ααφφπααδφπαφ⎧⎛⎞⎛⎞=+⎪⎜⎟⎜⎟⎝⎠⎝⎠⎪⎪⎨⎪⎛⎞⎪=⎜⎟⎪+⎝⎠⎩,(5) The estimation for the intensity values of each regionshould be done because these parameters in this modelare unknown before classification. In this paper, We use mean intensity values of each region as parameters. So the parameter estimation can be completed by the following formulation ()()ααφφΩΩ∗=∫∫0.ii iuH u H (6)C. Classification Functions in Term of Level Set The partition{}1 (i)i k=Ω based on the level set canbe achieved through the minimization of a global function. This global function contains four terms. In the following, each term will be expressed. Let define the first function related to (3)()αλφΩ=⎛⎞=−⎜⎟⎝⎠∑∫211.2k Ci i F H dxdy (7) The minimization of C F α penalizes the formation ofvacuum and region overlapping.i x t if x other The second function is related to external force and takes into account the parameter estimation.()()φ=Ω=−∈∑∫21,,kei i o i i i F e H u u dxdy e R wise(4)∀i (8)(a) (b)Fig.1 Regularized versions of the Heaviside function and.δ function (0.5α=). (a) The regularized versions of the Heavisidefunction. (b) Regularized versions of δfunction.We define parameters asiu()()ααφφΩΩ∗=∫∫.iiiu HuH(9)The third term in our model is related to boundaryalignment. Zero crossing of the second order derivativealong the gradient direction is introduced. And thenhe.observed that using only the gradient directioncomponent of the Laplacian yields better edges than thoseproduced by the zero crossing of the Laplacian.So the curve evolves along the second order derivativein the direction of the image gradient. Then the boundaryalignment term in our model is described as below()φΩ⎛⎞⎛⎞∇⎜⎟=Δ−∇∇⋅⎜⎟⎜⎟⎜⎟∇⎝⎠⎝⎠∫buF u u H dxdyu(10)where represents a gray level image.Letdefineu[]2):0,1R→(,u x y. The first order derivatives in thehorizontal and vertical directions are represented byxu and, respectively. We define the gradient directionvector fieldyu,x yu uuuξ∇==∇r(11)and the orthogonal vector filed,u uuuη−∇==∇r(12)Hence ξη=r r,()ξξξξξξξξξξ=∇∇=∇+=++⎛⎞∇=Δ−∇∇⋅⎜⎟⎜⎟∇⎝⎠1222121,,,2x yxx yy xyu uu uu u uuu uuξ2(13)This term is important for finding edges of thinstructures in images. However, this term alone isinsufficient for integrating all the edges. If the curve usedas an initial guess is far from the object boundaries, itmay fail to lock onto its edges. Therefore, another ‘force’that pushes curve toward the edges of the object isrequired.The fourth function that we want to introduce is relatedto internal force about minimization of the interfaceslength()γδφφγ=Ω=∇∈∑∫1,,kii i i iiF dxd∀.y R i (14)The last function in this model is related to re-initialization. It is crucial to keep the level set function asan approximate signed distance function during theevolution. The standard re-initialization method is tosolve the following equation()()1signtφφφ∂=−∂∇ (15)whereφis the function to be re-initialized, and()signφis the sign function. However, if 0φis notsmooth or much steeper on one side of the interface thanthe other, the zero level set function φcan be movedincorrectly. In this paper, we introduce a new term thatforces the level set function to be close to a signeddistance function, and therefore completely eliminates theneed of the costly re-initialization procedure. The term isdescribed as below0where,denotes inner product oftwo vectors. The edge detector finds the image locationswhere both ∇u is larger than some thresholdand, whereξξ=0uξξu is the second derivative of u inthe gradient direction. Then we can get the description ofξξu as below()μφ=Ω=∇−∑∫21112kinii i i F.dxdy (16) By minimizing (11), the corresponding partial differential equations of φ is given by()()0,0,,,.t x y x y φφφφφφ⎧⎛⎞∂∇=Δ−∇⋅⎪⎜⎟⎜⎟∂∇⎪⎝⎠⎪⎨⎪=⎪⎪⎩(17) To explain the effect of the term, we notice that thegradient flow11φφφφφ⎛⎞⎛⎞⎛⎞∇Δ−∇⋅=∇⋅−∇⎜⎟⎜⎟⎜⎟⎜⎟⎜⎟⎜⎟∇∇⎝⎠⎝⎠⎝⎠ (18) has the factor 11φ⎛−⎜⎜⎟∇⎝⎠⎞⎟ as diffusion rate. If φ∇>1, thediffusion rate is positive. It will make φ more even and therefore reduce the gradient φ∇. If φ∇<1b , the term has effect of reverse diffusion and therefore increase the gradient.We use an example, as shown in Fig 2 to explain the effect of this term. From the result we can see that even though the initial level set function in Fig 2(a) is not a signed distance function the evolving level set function, as shown in Fig 2(b), is maintained very close to a signed distance function. The result of evolution is represented in Fig 2(c)Thus taking into account the parameter estimation, the sum leads to the global functionc e i ini F F F F F ()()()()()()λφφγδφφμφφ=ΩΩ=Ω=Ω==Ω=++++⎛⎞+−⎜⎟⎝⎠+−+∇+∇−⎛⎞⎛⎞∇⎜⎟+Δ−∇∇⋅∗⎜⎟⎜⎟⎜⎟∇⎝⎠⎝⎠∑∫∑∫∑∫∑∫∑∫2121121112112.C e i ini bouki i ki i o i i ki i i i ki i i koo o i i oF F F F F F H dxdy e H u u dxdydxdydxdy u u u H dxdy u (19)D. Evolution and Numerical SchemeThe Euler Lagrange equations associated to F α can be achieved by minimizing the above global function F α. And then through it embedding into a dynamicalscheme by using the steepest descent method, we can get a set of equations()()()()()()()φφμφφδφφγδφφλδφφδφ=Ω⎛⎞⎛⎞∂∇⎜⎟=Δ−∇⋅⎜⎟⎜⎟⎜⎟∂∇⎝⎠⎝⎠−−⎛⎞∇−∗∗∇⋅⎜⎟⎜⎟∇⎝⎠⎛⎞+−⎜⎟⎝⎠⎛⎞⎛⎞∇⎜⎟−Δ−∇∇⋅⎜⎟⎜⎟⎜⎟∇⎝⎠⎝⎠∑∫211.iii i i i i o i ii i i k i i i oi o o o t e u u H uu u u (20)Thus the numerical algorithms of (20) can be written as()()()()()()()φφδφφδφγφλδφφδφ+=Ω=−∗−⎛⎞∇+∗∗∗∇⋅⎜⎟⎜⎟∇⎝⎠⎛⎞+∗−⎜⎟⎝⎠⎛⎞⎛⎞∇⎜⎟+∗Δ−∇∇⋅⎜⎟⎜⎟⎜⎟∇⎝⎠⎝⎠∑∫2111.t t i i i i o i i i i i k i i i oi o o o dt e u u dt dt H u dt u u u (21)IV.EXPERIMENTAL RESULTSIn this section we conclude this paper by presenting numerical results using our model on various synthetic and real images. In our numerical experiments, we general choose the parameters as follows: (the step space), 1h =1t Δ=(the time step). We use the approximations H α and αδof Heaviside and Dirac functions (0.5α=). These results show our model can complete the classification and get the better result although the parameters are unknown. The model also avoids the re-initialization in level set evolution.Fig.3 shows experiment on a synthetic image with three classes. In this experiment we use three level set functions. In Fig.3 (a) it is the result based on model without boundary alignment term. Fig.3 (b) is the result of our method. From the result it shows that although our method needn’t know parameters before classification itcan complete the classification tasks. So it can save much work to identify region parameters and get the better result, especially for dealing with the edge of square, by using the new boundary alignment term.(a) (b) (c)Fig.2: Evolution of level set function to explain the re-initialization term. (a) The initialization of level set function. (b) The evolutionof level set function. (c) The result of evolution.(a)(b)Fig.3 Classification for synthetic image based on parameters estimated method. (a) The result of the model without boundary alignment term. (b) The result based on our method. Parameters in the model are respectively: γγγ===∗∗1233255255,===12310,e e eλ=∗4410,μμμ−===∗2123510.In Fig.4, we show how our model works on a gaussnoise image with three classes. In this experiment we usethree level set functions. This noise picture is done by us.Fig.4 (a) shows the result based on model withoutboundary alignment term. In Fig.4 (b) we show the resultof classification based on our method. From the result itshows that although the image has noise our model cancomplete the classification tasks and get the better result,especially for dealing with the edges of three shapes.In Fig.5 it shows the experiment on an oil spills imagewith blurred boundaries. Spillage of oil in coastal waterscan be a catastrophic event. The potential damage to theenvironment requires agencies to rapidly detect and cleanup any large spill. In this experiment we use two level setfunctions. In Fig.5 (a) we show the original picture. InFig.5 (b) we show the result of classification based on ourmodel. The result shows that this model can rapidlydiscriminate oil spills from the surrounding waterIn Fig.6 we show the experiment on a medical image.This image is a 2D MR brain image with structures ofdifferent intensities and with blurred boundaries.(a)(b)Fig.4. Classification for a gauss noise image. (a) The result of the model without boundary alignment term. (b) The result ofclassification based on our model. Parameters in the model are respectively:γγγ===∗∗1233255255,===12310,e e e λ=∗4410,μμμ−===∗2123510.(a) (b)Fig.5. Classification for an oil spill image. (a) The origin image. (b) The result of classification based on our method. Parameters arerespectively:γγ==∗∗120.5255255,==12100,e e λ=∗4410,μμ−==∗412510.Fig.6. Classification for a medical image. (a).The origin image. (b) The result of classification based on our method. Parameters in the model arerespectively :1233255255,γγγ===∗∗4410,λ=∗12310,e e e ===In this experiment we use three level set functions. Fig.6 (a) shows the origin picture. Fig.6 (b) is the result of classification based on parameters estimation. The result shows that our model can force the curves to converge on the desired boundaries even though some parts of the boundaries are too blurred.V.C ONCLUSIONSIn this paper an unsupervised classification model based on level set is proposed. This new model has parameters estimation capability. Parameter estimation is automatically completed in classification process. This model also include a new term that forces the level set function to be close to a signed distance function So it eliminates the need of the re-initialization of level set function. In addition, a boundary alignment term is also included in this model that is used for segmentation of thin structures. The resulting of this new model is a set of Partial Differential Equations. These equations govern the evolution of the interfaces to a regularized partition, evenif the original image is noisy and has the structures with blurred boundaries. Finally this proposed model has been applied to both synthetic and real images with promising results. However, this new model only uses the spatial distribution of intensity. So this new model needs to be improved incorporating with other features of the image.A CKNOWLEDGMENTThis work was supported by the National Natural Science Foundation of China (Grant No.50936006).R EFERENCES[1]M. Berthod, Z. Kato, Y. Shan, and J. Zerubia, “Bayesianimage classification using Markov random fields,” Image.Vis. Comput., vol. 14, pp. 285–295, May. 1996.[2] C. Samson, L. Blanc-Féraud, G.Aubert, and J.Zerubia,“Multiphase evolution and variational image classification,” Tech. Rep. 3662, INRIA, Sophia AntipolisCedex, France, Apr.1999.[3] A. Hegerath, T. Deselaers,and H. Ney, “Patch-based objectrecognition using discriminatively trained Gaussian mixtures,” Br. Mach Vis Conf,Edinburgh, UK, pp. 519–528, 2006.[4]I. Laptev, “Improvements of object detection using boostedhistograms,” Br Mach Vis Conf, Edinburgh, UK, pp. 949-958, 2006.[5]S. Lazebnik, C. Schmid, and J. Ponce, “Beyond bags offeatures: Spatial pyramid matching for recognizing naturalscene categories,” Comput Soc Conf Comput.Vis. PatternRecognit, Washington, USA, pp.2169-2178, 2006.[6]J. Zhang, M. Marszalek, S. Lazebnik, and C. Schmid,“Local features and kernels for classification of texture andobject categories: a comprehensive study,” Int. J. Comput.Vis., vol. 73, pp.213–218, 2007.[7]S. Osher, J. A. Sethian, “Fronts propagating withcurvature-dependent speed: Algorithms based on Hamilton-Jacobi formulations”, J. Comput. Phys., vol.79,pp.12-49, 1988. [8] C. Samson, L.Blanc-Féraud, G.Aubert, and J.Zerubia, “ALevel Set Model for Image Classification,” Int. J. Comput.Vis, vol. 40, pp. 187–197, 2000.[9] C. Li, C. Xu, C. Gui and D.Martin, “Level set EvolutionWithout Reinitialization: A New Variontional Fomulation,” IEEE Int Conf. Comput. Vis. PatternRecognit., San Diego, vol.1, pp.430-436, 2005.[10]A. Vasilevskiy and K. Siddiqi, “Flux maximizinggeometric flows,” IEEE Trans. Pattern Anal. MachineIntell., vol. 24, pp. 1565– 1578, 2002.Zhong-Wei Li, born in 1979. He is currently a Ph. D degree candidate in college of physics science at Graduate Universityof Chinese Academy of Science, Beijing. His research interests include differential equations, medical simulation and image processing.。
图像缩放算法研究及其FPGA实现
图像缩放算法研究及其FPGA实现一、本文概述随着数字图像处理技术的不断发展,图像缩放作为其中的关键步骤,对于提高图像质量和处理效率具有重要意义。
本文旨在研究图像缩放算法的相关理论和技术,并探讨其在FPGA(Field-Programmable Gate Array)硬件平台上的实现方法。
通过对图像缩放算法的分析与优化,结合FPGA并行处理的优势,实现高效、精确的图像缩放功能。
本文首先介绍了图像缩放算法的基本原理和常见方法,包括最近邻插值、双线性插值、双三次插值等。
然后,对FPGA在图像处理领域的应用进行了概述,分析了FPGA并行处理的特点及其在图像处理中的优势。
在此基础上,提出了一种基于FPGA的图像缩放算法实现方案,并对该方案进行了详细的描述和分析。
本文的重点在于研究图像缩放算法在FPGA上的优化实现。
通过合理设计算法流程、优化数据结构和利用FPGA并行处理资源,实现了高效的图像缩放处理。
本文还对所实现的图像缩放算法进行了性能分析和评估,验证了其在实际应用中的可行性和优越性。
通过本文的研究,旨在为图像缩放算法的优化实现提供一种有效的FPGA解决方案,为数字图像处理技术的发展和推广做出贡献。
也为相关领域的研究人员和技术人员提供了一定的参考和借鉴。
二、图像缩放算法概述图像缩放,也称为图像重采样或图像分辨率调整,是数字图像处理中的关键步骤。
它涉及改变图像的尺寸,即在保持图像内容尽可能不变的前提下,增加或减少图像的像素数量。
图像缩放算法在多个领域都有广泛应用,如数字摄影、视频处理、医学影像分析以及计算机视觉等。
图像缩放算法的核心在于如何有效地插值或估算缺失的像素值。
根据插值方法的不同,常见的图像缩放算法可以分为最近邻插值、双线性插值、双三次插值等。
最近邻插值是最简单的方法,它直接选取离目标位置最近的像素值作为新像素的值。
双线性插值则考虑目标像素周围四个像素的影响,通过线性组合得到新像素的值。
双三次插值则更为复杂,它利用目标像素周围16个像素的信息进行插值,可以获得更高的图像质量。
常用图像压缩算法对比分析
常用图像压缩算法对比分析1. 引言图像压缩是一种将图像数据进行有损或无损压缩的方法,旨在减少图像数据的存储空间和传输带宽需求,同时尽可能保持原始图像的质量。
随着数字图像的广泛应用,图像压缩算法成为了计算机科学领域的重要研究领域。
本文将对目前常用的图像压缩算法进行比较和分析。
2. JPEG压缩算法JPEG(Joint Photographic Experts Group)是一种广泛使用的无损压缩算法,适用于彩色图像。
该算法通过对图像在频域上的离散余弦变换(DCT)进行分析,将高频成分进行舍弃,从而实现图像的压缩。
JPEG算法可以选择不同的压缩比,从而平衡图像质量和压缩率。
3. PNG压缩算法PNG(Portable Network Graphics)是一种无损压缩算法,适用于压缩有颜色索引的图像。
该算法基于LZ77压缩算法和哈夫曼编码,将图像中的相似数据进行压缩存储。
相比于JPEG算法,PNG 算法可以实现更好的图像质量,但压缩率较低。
4. GIF压缩算法GIF(Graphics Interchange Format)是一种无损压缩算法,适用于压缩简单的图像,如卡通图像或图形。
该算法基于LZW压缩算法,通过建立字典来实现图像的压缩存储。
GIF算法在保持图像质量的同时,能够实现较高的压缩率。
5. WEBP压缩算法WEBP是一种无损压缩算法,由Google开发,适用于网络上的图像传输。
该算法结合了有损压缩和无损压缩的特点,可以根据需要选择不同的压缩模式。
相比于JPEG和PNG算法,WEBP算法可以实现更好的压缩率和图像质量,但对浏览器的兼容性有一定要求。
6. 对比分析从图像质量、压缩率和兼容性等方面对比分析上述四种常用图像压缩算法。
- 图像质量:JPEG算法在高压缩比下会引入一定的失真,适合于要求相对较低的图像质量;PNG和GIF算法在无损压缩的情况下能够保持较好的图像质量;WEBP算法在高压缩比下相对其他算法都具有更好的图像质量。
图片缩放算法原理
图像缩放的双线性内插值算法的原理解析图像的缩放很好理解,就是图像的放大和缩小。
传统的绘画工具中,有一种叫做“放大尺”的绘画工具,画家常用它来放大图画。
当然,在计算机上,我们不再需要用放大尺去放大或缩小图像了,把这个工作交给程序来完成就可以了。
下面就来讲讲计算机怎么来放大缩小图象;在本文中,我们所说的图像都是指点阵图,也就是用一个像素矩阵来描述图像的方法,对于另一种图像:用函数来描述图像的矢量图,不在本文讨论之列。
越是简单的模型越适合用来举例子,我们就举个简单的图像:3X3 的256级灰度图,也就是高为3个象素,宽也是3个象素的图像,每个象素的取值可以是0-255,代表该像素的亮度,255代表最亮,也就是白色,0代表最暗,即黑色。
假如图像的象素矩阵如下图所示(这个原始图把它叫做源图,Source):234 38 2267 44 1289 65 63这个矩阵中,元素坐标(x,y)是这样确定的,x从左到右,从0开始,y从上到下,也是从零开始,这是图象处理中最常用的坐标系,就是这样一个坐标:---------------------->X|||||∨Y如果想把这副图放大为 4X4大小的图像,那么该怎么做呢?那么第一步肯定想到的是先把4X4的矩阵先画出来再说,好了矩阵画出来了,如下所示,当然,矩阵的每个像素都是未知数,等待着我们去填充(这个将要被填充的图的叫做目标图,Destination):? ? ? ?? ? ? ?? ? ? ?? ? ? ?然后要往这个空的矩阵里面填值了,要填的值从哪里来来呢?是从源图中来,好,先填写目标图最左上角的象素,坐标为(0,0),那么该坐标对应源图中的坐标可以由如下公式得出:srcX=dstX* (srcWidth/dstWidth) , srcY = dstY * (srcHeight/dstHeight)好了,套用公式,就可以找到对应的原图的坐标了(0*(3/4),0*(3/4))=>(0*0.75,0*0.75)=>(0,0),找到了源图的对应坐标,就可以把源图中坐标为(0,0)处的234象素值填进去目标图的(0,0)这个位置了。
一种基于映射图像子块的图像缩小加权平均算法
一种基于映射图像子块的图像缩小加权平均算法
高健;茅时群;周宇玫;叶静
【期刊名称】《中国图象图形学报》
【年(卷),期】2006(011)010
【摘要】针对一般缩小算法随着缩小比例降低,图像信息丢失愈发严重的现象,提出了一种基于映射图像子块的图像缩小加权平均算法.首先,根据缩小比例,求出缩小图像中每点映射在原始图像中的子块,然后,根据各子块,加权平均算出缩小图像中每点的像素值,从而达到缩小的目的.缩小后的图像具有较好的完整性,且算法简单、快速有效.实验结果表明,该算法与其他缩小算法相比,在保持图像完整性方面具一定的特点.最后,针对缩小后图像对比度偏低这一现象,提出了一种灰度拉伸的处理方法,并进行了实验对比,取得了较好效果.
【总页数】4页(P1460-1463)
【作者】高健;茅时群;周宇玫;叶静
【作者单位】上海大学-纽帝亚联合媒体研究中心,上海,200072;上海大学-纽帝亚联合媒体研究中心,上海,200072;上海大学-纽帝亚联合媒体研究中心,上海,200072;上海大学-纽帝亚联合媒体研究中心,上海,200072
【正文语种】中文
【中图分类】TP391.4
【相关文献】
1.一种基于小波系数加权平均的Retinex图像增强算法 [J], 薛培;薛国新;张亚洲;刘强
2.一种基于小波系数加权平均的Retinex图像增强算法 [J], 薛培;薛国新;张亚洲;刘强
3.基于图像子块加权缩小的自适应修正算法 [J], 常军;吴锡生
4.一种基于角点信息和加权子块的图像缩小算法 [J], 徐御
5.基于多特征盒计数图像子块的道路图像的缩小 [J], 刘晟
因版权原因,仅展示原文概要,查看原文内容请购买。
图像缩放算法中常见插值方法比较
图像缩放算法中常见插值方法比较
陈高琳
【期刊名称】《福建电脑》
【年(卷),期】2017(033)009
【摘要】本文综合介绍了图像缩放算法中常用的几种插值方法,并对几种算法的基本原理和优缺点进行描述.最后通过实际的原始图像使用不同的图像缩放差值算法得到的输出结果,对比并阐述其不同的效果.
【总页数】2页(P98-99)
【作者】陈高琳
【作者单位】福建师范大学数学与信息学院福建福州 350007
【正文语种】中文
【相关文献】
1.聚束SAR成像算法中的几种插值方法比较 [J], 曾海彬;曾涛;胡程;朱宇
2.比较阅读中常见的比较点--从2005年中考文言文阅读题说起 [J], 张翼
3.基于R-D算法的合成孔径声纳插值方法比较 [J], 丁迎迎;孙超
4.实现图像缩放功能的Matlab插值算法研究与比较 [J], 丁雪晶
5.三种常见插值方法思想比较及适应性分析 [J], 于秀君
因版权原因,仅展示原文概要,查看原文内容请购买。
图像压缩算法的性能比较与分析
图像压缩算法的性能比较与分析一、引言图像是数字媒体中的重要形式之一。
图像文件通常非常大,当它们用于互联网、移动设备和存储时,大尺寸的图像会带来许多问题,例如占用太多的存储空间、传输速度缓慢、带宽限制等。
为了解决这些问题,图像压缩技术被广泛应用。
目前,常用的图像压缩算法有无损压缩和有损压缩两种类型。
它们在不同情况下有着相应的应用。
本文将介绍图像压缩的基本概念和不同算法的性能比较与分析。
二、基本概念2.1 无损压缩无损压缩是指对图像进行压缩,在压缩后的文件进行解压缩还原的图像与原始图像之间没有任何差异的压缩方法。
这种压缩方法是分析原始图像的重复模式,并学会使用更简单的指令表示这些模式。
无损压缩通常不会去掉图像本身中的任何信息,只是减小了文件的大小。
2.2 有损压缩有损压缩是指对图像进行压缩,在压缩后的文件进行解压缩还原的图像与原始图像之间有些许差异的压缩方法,这种差异可以通过人的肉眼来识别。
有损压缩方法通常通过去掉不重要的图像信息来减小文件大小。
2.3 像素在数字图像中,图像被分成很多缩小的单元格,这些单元格被称为像素。
每个像素包含有颜色和亮度信息。
2.4 分辨率在数字图像中,分辨率是指图像所包含的像素数量。
通常来说,分辨率越高,图像就越清晰。
三、图像压缩算法3.1 LZW算法LZW算法是最常用的无损压缩算法之一。
它基于一种字典,包含了所有可用的数据。
在使用LZW算法压缩图像时,其将存储在图像中的像素数据序列替换为相应的压缩代码。
如果LZW算法的压缩率足够高,则它可以有效地减少图像的大小。
3.2 JPEG算法JPEG是一种有损压缩算法。
它是基于离散余弦变换的,也被称为DCT算法。
JPEG算法通过分离图像中不同区域的颜色和亮度信息来减少文件大小。
在JPEG算法中,亮度信息被整合为一种通道(Y通道),而颜色信息被分离成另外两种通道(U和V通道)。
JPEG算法可以根据压缩比例的要求进行优化。
3.3 PNG算法PNG是Portable Network Graphics的缩写,是一种无损压缩算法。
几种最新的图像缩放方法的比较性研究的开题报告
几种最新的图像缩放方法的比较性研究的开题报告提纲:1.研究背景:图像缩放的应用和重要性2.研究问题:现有的图像缩放方法的不足和需要改进之处3.研究目的:评估几种最新的图像缩放方法的性能差异和适用性4.研究方法:实验评估和比较、数据分析和可视化5.预期结果:几种最新的图像缩放方法的性能差异和适用性6.研究意义:为图像缩放领域的技术发展提供参考和帮助优化图像处理和媒体应用。
正文:1.研究背景:图像缩放在计算机视觉和图像处理方面得到了广泛的应用,例如数字媒体和数字化文化遗产,身份验证、医学诊断和多媒体通信等领域。
图像缩放允许将图像的尺寸调整为不同的应用要求。
尽管存在多种方法可以实现图像缩放,但最新的图像缩放技术旨在提高缩放输出图像质量并减少图像失真。
2.研究问题虽然有许多图像缩放方法可供选择,但每种方法都有其优缺点。
例如,传统的双线性和双三次插值方法可能会导致图像加权平均和图像失真。
为了克服这些缺陷,研究人员提出了许多新的图像缩放方法,如超分辨率、深度卷积、反卷积网络、GAN等。
这种方法利用大量的训练数据,采用复杂模型,旨在更好地处理高分辨率图像。
但是,这些新方法是否在性能和适用性方面比传统的图像缩放方法更好,例如Bicubic缩放,目前尚未完全确定。
本研究旨在评估和比较几种最新的图像缩放方法(如超分辨率、深度卷积、反卷积网络和GAN等),并确定它们在图像缩放方面的性能和适用性。
首先,十几种方法将分为不同的组,并对其进行准确的实验评估和比较。
然后,将收集、分析和可视化结果数据,以确定每种方法的影响和优势。
4. 研究方法(1)收集数据集和图像样本选择公开的数据集或自定几个不同类型的、不同分辨率的图像样本进行实验,并比较为同一大小的输出图像。
(2)实验评估和比较根据前面阐述的几种方法,将数据集或图片样本分成不同的实验组,提供相应的参数和设置详细的实验环境,比较结果的不同(3)数据分析和可视化收集和比较各种方法的数据,对结果进行可视化或绘制图形,并分析所得数据,寻找差异或趋势。
几种图像缩放算法的研究
几种图像缩放算法的研究李秀英;袁红【摘要】There are several kinds of image scaling methods in time domain: nearest neighbor interpolation, linear interpolation, quadratic interpolation, cubic interpolation, Lagrange interpolation, Gaussian interpolation, etc. The performance of these methods are compared according to passband, stopband and cutoff frequency. The result shows that the nearest interpolation and the linear interpolation should be avoided, and Gaussian basis function whose N value is larger has better performance. The 2-D nonseparable interpolation filter and 2-D separable in-terpolation filter are studied. With the requirements of passband and stopband as optimizing target, and the struc-ture of filter as constraint condition, the filter design for them is converted into an optimization problem. The ex-periment result shows that the 2-D nonseparable interpolation filter has better performance.%时域内常用的几种图像缩放算法有:最近邻插值、线性插值、二次插值、三次插值、拉格朗日插值、高斯插值等,对这些算法的性能进行分析比较,综合通带、阻带及截止频率,最近邻插值和线性插值应该避免,高斯基函数(N较大者)具有较好性能;并且在频域内研究了二维可分离插值滤波器和不可分离插值滤波器,这两种方法以对通带和阻带的要求作为优化目标,以滤波器的结构为约束条件,将滤波器的设计转化为一个约束优化问题进行解决;实验结果表明二维不可分离插值滤波器的方法图像缩放后的效果最好.【期刊名称】《现代电子技术》【年(卷),期】2012(035)005【总页数】4页(P48-51)【关键词】插值滤波器;图像尺度变换;变量分离;采样率转换【作者】李秀英;袁红【作者单位】上海电力学院数理系,上海200090;临沂师范学院数学系,山东临沂276005【正文语种】中文【中图分类】TN911.73-34;TP3910 引言在实际应用中,经常需要对数字图像进行尺度转换,在改变图像尺寸方面,文献[1-8]提出了通过三次样条插值、三次卷积插值、二维快速傅立叶变换进行图像尺寸转换的方法;这些算法比较简单,性能受到了明显的限制。
图像缩放算法的研究及VLSI实现的开题报告
图像缩放算法的研究及VLSI实现的开题报告1. 研究背景图像缩放是数字图像处理中的基本操作之一,其作用是在不改变图像内容的情况下改变图像的大小。
在实际应用中,图像缩放经常用于图像压缩、图像增强、图像重构等领域。
因此,图像缩放算法的研究和实现具有重要意义。
在图像缩放算法的研究中,常用的算法包括双线性插值法、双立方插值法、最近邻插值法等。
这些算法各有优劣,并且在实际应用中需要根据情况选择不同的算法进行实现。
另外,随着VLSI技术的不断发展,基于硬件的图像缩放实现也越来越受到关注。
基于VLSI的图像缩放实现具有运行速度快、功耗低等优点,同时也面临着硬件设计复杂、成本高等挑战。
因此,本文将着重探讨图像缩放算法的研究以及基于VLSI的图像缩放实现。
2. 研究内容本文将从以下几个方面进行研究:(1)图像缩放算法的研究本文将对常用的图像缩放算法进行研究分析,包括双线性插值法、双立方插值法、最近邻插值法等,并比较各个算法的优缺点和适用场景。
(2)VLSI实现的图像缩放算法本文将基于FPGA平台进行VLSI实现的图像缩放算法。
主要研究内容包括硬件设计、异步处理、片上存储等方面,并建立完整的图像缩放VLSI实现体系。
(3)实验验证本文将设计实验对比图像缩放算法的运行速度、功耗等性能指标。
同时,通过对比不同算法的实现效果,验证本文的设计方法的有效性。
3. 研究意义本文将从两个方面具有研究意义:(1)图像缩放算法的优化本文将对常用的图像缩放算法进行研究和优化,从而提高算法的准确性和实用性。
(2)基于VLSI的图像缩放实现本文将以FPGA为代表的VLSI平台进行图像缩放实现,从而提高图像缩放处理的速度和效率。
这对于需要在实时环境下进行图像处理的应用具有重要意义。
4. 研究方法本文采用的研究方法主要包括理论分析、仿真实验和硬件实现等。
其中,理论分析主要对图像缩放算法进行研究和优化;仿真实验通过软件工具进行图像缩放算法实现和性能评测;硬件实现则基于FPGA平台进行图像缩放算法的VLSI实现。
基于二元估算工具的最大后验概率准则芯片图像去噪(IJIGSP-V5-N1-5)
I.J. Image, Graphics and Signal Processing, 2013, 1, 32-39Published Online January 2013 in MECS (/)DOI: 10.5815/ijigsp.2013.01.05Noise Removal From Microarray Images Using Maximum a Posteriori Based Bivariate EstimatorA.Sharmila AgnalAssistant Professor, Department of Computer Science and Engineering,National Engineering College, Kovilpatti, India.E-mail: sharsa.agnal09@Dr. K.MalaProfessor, Department of Computer Science and Engineering,Mepco Schlenk Engineering College, Sivakasi, India.E-mail: kmala@mepcoeng.ac.inAbstract—Microarray Image contains information about thousands of genes in an organism and these images are affected by several types of noises. They affect the circu-lar edges of spots and thus degrade the image quality. Hence noise removal is the first step of cDNA microarray image analysis for obtaining gene expression level and identifying the infected cells. The Dual Tree Complex Wavelet Transform (DT-CWT) is preferred for denoising microarray images due to its properties like improved directional selectivity and near shift-invariance. In this paper, bivariate estimators namely Linear Minimum Mean Squared Error (LMMSE) and Maximum A Poste-riori (MAP) derived by applying DT-CWT are used for denoising microarray images. Experimental results show that MAP based denoising method outperforms existing denoising techniques for microarray images.Index Terms—cDNA Microarray Images, Denoising Microarray Images, Bivariate LMMSE estimation, Biva-riate MAP estimation, Dual Tree Complex Wavelet Transform.I.INTRODUCTIONThe arrival of microarray imaging technology has lead to enormous progress in the life sciences by allowing scientists to analyze the expression levels of thousands of genes at a time. It is a powerful tool for discovering vari-ous types of diseases and for diagnosing the type of dis-ease based upon gene expression measurements. But the noise introduced in microarray images gives rise to a challenge for engineers to interpret the meaning of the immense amount of biological information formatted in numerical matrices from the expression levels of thou-sands of genes, possibly all genes in an organism.The two-channel complementary DNA (cDNA) micro-array is designed to measure the activity of a set of genes under two conditions, namely, treatment and control [20].A typical cDNA microarray experiment consists of the following major steps. Messenger RNA from control and treatment samples are converted into cDNA, labeled with fluorescent dyes (green Cy3 dye for control, red Cy5 dye for treatment) and mixed together. The mixture is then washed over a slide spotted with probes, which are DNA sequences from known genes. During this stage, competi-tive hybridization occurs, which is the pairing of the fluo-rescent cDNA to the spotted probes. Next, the slide is scanned to produce two 16-bit images, one for the green channel and another for the red. Each spot on the images consists of a number of pixels, wherein the brightness of each pixel reflects the amount of Cy3 or Cy5 at the spa-tial location corresponding to that pixel. Thus, one can identify the genes that are differentially expressed be-tween the two samples by comparing the pixel intensities of each spot in the red and green channel images.This paper introduces a technique for removing noise from microarray images based on Complex Wavelet Transforms. There are two major approaches of statistical wavelet-based denoising algorithms. In the first approach, the wavelet coefficients are modified using certain threshold parameters and shrinkage functions. The se-cond and better approach is to formulate the denoising algorithm as an estimation technique for the noise-free wavelet coefficients of images by minimizing a Bayesian risk, typically under the Minimum Mean Squared Error (MMSE) or Maximum A Posteriori (MAP) criterion . Denoising algorithms that assume the wavelet coeffi-cients of the entire subband are independent and identi-cally distributed (i.i.d.), are called subband-adaptive.II.RELATED WORKStudies show that microarray images are corrupted by several types of noise that result from the imaging system. Some examples of these noises include electronic noise, photon noise, dark current noise, and quantization noise [9], [21]. Noise may also be introduced from other sources such as nonspecific hybridization to the probes on the microarray surface and dust on the glass slide [22]. Statistical distributions such as the Gaussian [9], Poisson [1] and Exponential distributions [5] have been used to describe the noise characteristics of microarray imagesconsidering additive or multiplicative noise model [2]. It is to be noted that many non-additive and non-Gaussian noise models for images can be mathematically remod-eled as the additive Gaussian noise. Since the underlying processes that generate noise in the red and green channel images of cDNA microarrays are similar, it is expected that the noise are correlated between the two channels. The reduction of such correlated Gaussian noise is an important problem for processing of microarray images. Reduction of noise from microarray images can be per-formed in the pixel-domain [9], or in a transform domain [18].Although the pixel-based methods are simpler to im-plement in general, methods developed using an appro-priate transform domain are more efficient in reducing noise. Among the various transforms, the Discrete Wave-let Transform (DWT) has shown a significant success in image de-noising due to its space-frequency localization and high energy compaction properties, and flexibility of choosing a suitable basis function [10]. Further, the DWT being a multi-resolution analysis allows one to efficiently process an image at more than one resolution. For this reason, the DWT is gaining attention among researchers for developing new techniques to conduct several tasks in the microarray experiments such as gridding, spot recog-nition and analysis of differential gene expression [17]. A wavelet-based noise reduction algorithm may be embed-ded into the routines of such wavelet-based techniques for analyzing gene expression data so that the entire pro-cess of image processing and data analysis becomes fast-er, automated, and efficient. The Complex Wavelet Transform (CWT) is preferred to the discrete wavelet transform for de-noising of microarray images due to its improved directional selectivity for better representation of the circular edges of spots and near shift-invariance property.The better approach is to formulate the denoising algo-rithm as an estimation technique for the noise-free wave-let coefficients of images by minimizing a Bayesian risk, typically under the Minimum Mean Squared Error (MMSE) [15] or Maximum A Posteriori (MAP) criterion [11]. Denoising algorithms that assume the wavelet coef-ficients of the entire subband are independent and identi-cally distributed (i.i.d.), are called subband-adaptive. It is well known that the wavelet coefficients have strong in-trasubband and weak interscale dependencies. Hence, locally-adaptive methods that estimate a wavelet coeffi-cient from its local neighboring region provide a better denoising performance as compared to the subband-adaptive ones. A few methods have considered both the intrasubband and interlevel dependencies while denoising an image [12]. These methods provide slightly better denoising performance than those that use only intrasub-band dependency, but at the expense of increased compu-tational complexity. In this paper, two bivariate estima-tors namely Maximum A Posteriori (MAP)and Linear Minimum Mean Squared Error (LMMSE) are presented for the CWT-based denoising of microarray images.III.DENOISING USING COMPLEX WAVELETTRANSFORMThe Complex Wavelet Transform (CWT) differs fromthe DWT in having complex-valued scaling and wavelet functions, viz., ɸ1 + jɸ2and ψ1 + jψ2, respectively, and form Hilbert pairs [13], [14]. Various methods have beenproposed for obtaining CWT coefficients [8], however,due to the simplicity of implementation and lower redun-dancy, the dual-tree CWT (DT-CWT) that has been pro-posed by Kingsbury [8] and later generalized by Se-lesnick [13], is becoming popular. The DT-CWT consistsof two trees of DWT in parallel and provides four pairs ofsub-bands (Figure.1). The implementation of DT-CWT requires that the functions ɸ1 and ψ1 operate on the odd numbered data samples, and ɸ2 and ψ2 operate on theeven numbered data samples.Figure 1: DT-CWT sub-band decompositionThus, in general, processing of the magnitude compo-nents of an image is more efficient than that of the phase components. The choice of scaling and wavelet functions of DT-CWT is such that this transform can capture six directional features, namely, 15, 45 and 75 and -15,-45,and -75 degrees of an image. Hence, the CWT pro-vides a better directional selectivity as compared to the DWT that has only three angle-selective sub-bands. In order to improve the shift-invariance property, the DT-CWT avoids down-sampling operation in the first-level decomposition. Hence, the CWT has much lower shift sensitivity than the DWT.A.Estimation of CWT CoefficientsLet f r(i,j) and f g(i,j) be pixels of the red and green channel images, respectively, at the spatial location. As-sume that these pixels are corrupted by additive noise. Then, the noisy pixels are given as in (1),g r(i,j)= f r(i,j) + εr(i,j)g g(i,j)= f g(i,j) + εg(i,j) (1) Where εr(i,j) and εg(i,j) are the noise samples at refer-ence location. It is assumed that noise-samples of the red and green channel images are correlated and distributed as i.i.d. zero mean bivariate Gaussian having equal vari-ance σε2and correlation coefficient ρε. The standard devi-ation σε indi cates the strength of noise and ρε measuresthe amount of linear dependency of noise between chan-nels.B. Denoising AlgorithmDe-noising algorithm (Figure.2) consists of the follow-ing steps:-1) Add Gaussian noise of different strengths and com-pute the Complex Wavelet Transform of the noisy image.2) Modify the noisy wavelet coefficients according to LMMSE and MAP estimators,that take into account the inter-channel dependency of the magnitude components of CWT coefficients of the image.3) Compute the Inverse Complex Wavelet Transform using the modified coefficients for getting the de-noised image.4) Perform Gridding and Segmentation of de-noisedimage in order to estimate the Log Intensity Ratio.Figure 2: Steps for denoising microarray imagesThe wavelet coefficients in the lower level subbands are dominated by noise unlike that in the higher levels. As a consequence, overall denoising performance is high-ly dependent upon the efficiency of noise removal from the subbands at the lower levels. In other words, it is more important to choose a joint probanility density func-tion (pdf) that provides a better fit to the magnitude com-ponents of the subbands in a lower level to achieve a sat-isfactory denoising performance. Hence, for the purpose of denoising, the bivariate Gaussian pdf is an appropriate choice. In addition, an attractive feature of bivariate Gaussian pdf is that it is mathematically tractable for developing an estimator. So the bivariate LMMSE and MAP estimators are derived using this pdf as a joint prior function [16].C. Bivariate LMMSE EstimatorLet x = [x r ,x g ]T , y = [y r ,y g ]T and v=[v r ,v g ]T be the sam-ples of the random vectors X,Y and V representing mag-nitude components of the noise-free coefficients, noisy coefficients and noise coefficients respectively. TheLMMSE estimator for x given the corrupted observation y is a linear function of y that can be written in (2),)(1'Y Y XY X y x μμ-∑∑+=- (2)Where µX and µY are the mean of the random vectors X and Y, ΣXY is the cross-covariance matrix of X and Y,and ΣY is the covariance matrix of Y . The matrices may be written as in (3) and (4),}))({(T Y X XY Y X E μμ--=∑ (3) and}))({(T Y Y Y Y Y E μμ--=∑ (4)Where E{.} is the mathematical expectation. Since the image and additive noise are independent, μY = μX + μV and ΣXY = ΣX , where μV is the mean vector of V, μX is the mean vector of X, and ΣX is the covariance matrix of X . D. Bivariate MAP EstimatorThe MAP estimator for x given the corrupted observa-tion y is the mode of the posterior density function ρX|Y (x|y) and is given in (5).))|(max(arg )(|,y x y x Y X ρ=(or))](ln )([ln(max arg )('x x y y x X V xρρ+-= (5)Where ρX (.) is the bivariate Gaussian pdf and ρV (.) is the bivariate Rayleigh pdf. Then the bivariate MAP esti-mator for red and green channel images is given in (6).())0,44)(2)(21max(42242222222^⎪⎪⎭⎫ ⎝⎛++--+++=v r v r r r v v r r v r v r r y y x σσσσμσσμσσσσ())0,44)(2)(21max(42242222222^⎪⎪⎭⎫ ⎝⎛++--+++=v g v g g g v v g g v g v g g y y x σσσσμσσμσσσσ (6) E. Log Intensity Ratio(R) EstimationThe purpose of microarray image denoising is to im-prove the extraction of information regarding gene ex-pression levels instead of visual enhancement as in tradi-tional image denoising. Therefore, a successful microar-ray denoising algorithm is one that reduces noise withminimal loss of information for downstream statistical analysis. In cDNA microarray experiments, information regarding gene expression is commonly expressed in terms of the log-intensity ratio(R) that is given in (7), ⎪⎪⎪⎪⎪⎭⎫ ⎝⎛--=∑∑g rSgg S r r b S n b S nR 11log 2 (7) Where S r and S g denote the pixels of red and green channel images respectively and n is the number of pixelsin the region of interest(ROI) and b r and b g are the medi-an of the pixels of local background corresponding to the ROI of two channels.To calculate R, the first step is to identify target areas in the red and green channel images. In general, the target area is a square or rectangular region on an image enclos-ing one spot. These regions are identified by placing a grid over the entire image. The next step, known as seg-mentation, consists of identifying the pixels that belong to the ROI and background in a target area. There exist several segmentation methods, each having certain ad-vantages and drawbacks. Some of these methods have been compared in [22] and [19]. In this paper, an adap-tive segmentation technique is implemented that is a hy-brid of the fixed circle-based [3] and histogram-based [7] segmentation methods, in order to benefit from the ad-vantages of both these methods. Segmentation is per-formed separately for the red and green channel images. The hybrid segmentation method has the following two notable features that make it superior to the traditional fixed circle and histogram-based segmentation methods. First, the ROI selected by this method does not assume any perfectly circular shape at the center of target area as in the case of fixed circle-based method. Thus, the hybrid method provides a better separation of foreground when the spots have varying radii, irregular shapes, or spatial offsets from the center of the target area. Secondly, in selecting the pixels for a spot and its corresponding back-ground the hybrid segmentation method considers the spatial contexts that are ignored in the histogram-based method.IV.IMPLEMENTATION DETAILSThe experiments are conducted on a set of microarray images that have been downloaded from the website of the Stanford MicroArray Database[23] and [24]. In order to conduct the experiments original noise-free images are necessary. Since perfectly noise-free images are not available in practice, noise-free images those that appear to be corrupted with very little noise are chosen.The im-ages that have been used in the experiments are of size1000 x 1000 in 16-bit tagged image file format (.TIFF). The algorithm is implemented in MATLAB. A.AlgorithmInput: Noisy microarray imageOutput: De-noised imagebeginSymmetric extension of noisy image by calling symextend functiondoApply DT-CWT by calling cplxdual2Dfunctionuntil level<=4Modify CWT coefficients by calling lmm-se_estimator or map functiondoApply inverse DT-CWT by calling icplxdual2D functionuntil level<=4ender Defined FunctionsThe functions implemented are discussed below in de-tail.∙symextend(x,2^(J-1)): This function performs the symmetric extension of the pixels in the noisy im-age by taking the noisy pixel values (x) and thenumber of levels (J) as inputs.∙cplxdual2D(x, J, af, sf): This function calculates the DT-CWT coefficients by taking the noisy im-age (x), number of levels (J), analysis (af) and syn-thesis (sf) filter results for trees as arguments.∙normcoef(W,J,nor): This function calculates the normalized coefficient values by taking the noisyCWT coefficients (W) and number of DT-CWTstages (J) as inputs.∙expand(Y_parent_real): This function expands the real coefficient values.∙expand(Y_parent_imag):This function expands the imaginary coefficient values.∙lmmse_estimator(Y_coef,Y_parent):This function estimates the LMMSE estimator values by takingthe noisy CWT coefficients (Y_coef) and parentcoefficients (Y_parent) as inputs.∙map(Y_coef,sigmar,sigmag,m1,m2): This function calculates the MAP estimator values by taking thenoisy CWT coefficients (Y_coef), standard devia-tion (sigmar,sigmag) and mean (m1,m2) of red andgreen channel images as arguments.∙bishrink(Y_coef,Y_parent,T): This function modi-fies the noisy CWT coefficients by taking the es-timated CWT values (Y_coef), parent coefficient(Y_parent) values and threshold (T) values as in-puts.∙icplxdual2D(W, J, Fsf, sf): This function performs inverse DT-CWT operation by taking estimatedcoefficient values (W), number of decompositionlevels (J) and synthesis filter (Fsf, sf) results as in-puts.C.Assessment MeasuresThe de-noising performance of the algorithm is quanti-fied in decibels (dB) using the peak signal-to-noise ratio (PSNR) which is given in (8).⎪⎪⎭⎫⎝⎛=)'(65535log10)'(210fMSEfPSNR (8)Where MSE(f’) is the mean squared error of the d e-noised image f’. This measure is inversely proportional to the residual error in an image.Signal-to-noise ratio (often abbreviated SNR or S/N) is a measure used in science and engineering to quantify how much a signal has been corrupted by noise. It is de-fined as the ratio of signal power to the noise power cor-rupting the signal. A ratio higher than 1:1 indicates more signal than noise.MSEc r I SNR ∑=2),( (9)Where MSE is the Mean Squared Error which is the difference between the original image and the denoised image and I means original image (without noise), r means row, and c means column of the microarray image. Image fidelity (IFy) refers to the ability of a process to render an image accurately, without any visible distortion or information loss. Image fidelity is measured in physi-cal characteristics (luminance, dynamic range, distortion, resolution, and noise) and with psychophysical tech-niques, including receiver operator characteristics analy-sis with clinical images and testing with contrast-detail patterns to determine threshold contrast. SNRIFy 11-= (10) Where SNR is the Signal to Noise Ratio.Image quality is a characteristic of an image that measures the perceived image degradation (typically, compared to an ideal or perfect image). Imaging systems may introduce some amounts of distortion or artifacts in the signal, so the Correlation Quality (CQy) assessment is an important problem.),(),(*),(c r I c r I c r I CQy d ∑∑=(11)Where for an image of R*C (rows-by-columns) pixels, r means row, c means column, I means original image (without noise), and I d means denoised image.Image quality loss resulting from artifacts depends on the nature and strength of the artifacts as well as the con-text or background in which they occur. In order to in-clude the impact of image context in assessing artifact contribution to quality loss, regions must first be classi-fied into general categories that have distinct effects on the subjective impact of the particular artifact. These ef-fects can then be quantified as Structural Content (SCt) which is used to scale the artifact in a perceptually mean-ingful way.22),(),(c r I c r I SCt d ∑∑= (12)Where for an image of R*C (rows-by-columns) pixels, r means row, c means column, I means original image (without noise), and I d means denoised image.V. EXPERIMENTAL RESULTSNoisy images are created by adding bivariate Gaussian noise to the noise-free images considering four values of standard deviation, viz., 500, 600, 700,and 800. Figure 3 and Figure 4 shows the denoising results of a microarray image by applying Dual tree Complex Wavelet Trans-form on both red and green channel images separately. Also, Figure 5 represents the Gridding and Segmentation steps of the denoised images needed for the estimation oflog intensity ratio.(a) (b) (c)Figure 3: (a) Noise free Microarray Image Array 1. (b) Noisy Red Channel Image. (c) Noisy Green Channel Image. Here Noisy images areformed by adding Gaussian noise of standard deviation σ=500(a) (b) (c)Figure 4: Denoised Images obtained by applying Dual Tree Complex Wavelet Transform (a) Denoised Image (b) Red channel Image (c)Green Channel ImageCalculated PSNR values are tabulated in Table 1.Higher PSNR implies a better noise reduction perfor-mance. Also, the log-intensity ratio values are estimated from the denoised images. Table 2 tabulates the average PSNR values and Log intensity ratio estimated using both LMMSE and MAP estimator techniques by applyingdifferent noise strengths on the microarray images.(a) (b) (c)Figure 5: (a) Denoised Image (b) Gridding (c) SegmentationBased on the estimated Log intensity ratio (R) values, the expression of genes in the microarray images are measured as follows.✓ R=0 means gene is expressed equally in both con-trol and treatment sample. ✓ R<0 means gene is expressed more in controlsample. ✓ R>0 means gene is expressed more in treatmentsample.Table 1: PSNR values estimated in Db at various Noise Strengths forMicroarray Image Array1Table 2: Average PSNR values and Log intensity ratio estimation ofStanford Microarray Database ImagesFigure 6 shows the denoising results of another micro-array image obtained by applying Dual tree Complex Wavelet Transform on both red and green channel imag-es separately. Figure 7 shows the PSNR values estimated for different noise strengths by both LMMSE and MAP estimator method for two microarray images. It shows that, increase in Noise Strength decreases the PSNR Val-ues. This implies that when more noise is present, per-formance of LMMSE and MAP decreases. The algorithm gives good results for the Gaussian noise having standarddeviation below 750.Figure 6: (a) Noisy Image Array2 (b) Denoised image (c) Denoised redchannel image (d) Denoised green channel imageFigure 7: Performance analysis ofproposed method (a) LMMSE methodand (b) MAP method.The other assessment parameters that are used to eval-uate the performance of noise reduction of microarray images are Signal to Noise Ratio (SNR), Image Fidelity(IFy), Correlation Quality (CQy), and Structural Content (SCt). These parameters are estimated for determining the quality of denoised microarray images. Table 3 shows the estimated parameter values for the given denoising algorithm.The presented denoising method based on DT-CWT is compared with the existing BiShrink Method for calculat-ing CWT coefficients proposed by I.W.Selesnick. Table 4 tabulates the average PSNR values calculated by LMMSE, MAP estimators and BiShrink Method. Also, compared with other de-noising techniques by applying filters like median and wiener at various noise strengths by adding Gaussian noise. Table 5 and Table 6 tabulates the assessment parameters like PSNR, SNR, Image Fidel-ity (IFy), Correlation Quality (CQy), and Structural Con-tent (SCt) estimated by applying Median filter and Wie-ner filter on various microarray images. Higher values of SNR show better de-noising performance.Table 3: Performance MeasurementsTable 4: Performance ComparisonFigure 8 shows the average PSNR values estimated in dB for microarray images by applying Gaussian noise and using techniques like LMMSE, MAP, BiShrink method, Median and Wiener Filters. From the Figure 8, it is understood that the proposed LMMSE and MAP Esti-mator techniques show better de-noising performance than other methods. Also, Wiener filter results shows better denoising performance than Median filter and BiShrink method.Table 5: Performance measures of Median filterTable 6: Performance measures of Wiener filterFigure 8: Comparison of PSNR values of various methodsHence, the experimental results obtained by conduct-ing the five denoising experiments on the available mi-croarray data set shows that the denoising algorithm us-ing DT-CWT with MAP estimator outperforms the other denoising algorithms.VI.CONCLUSIONThe cDNA microarray images are contaminated by dif-ferent sources of noise that are introduced during various steps of the microarray experiments. The noise must first be reduced from these images for extraction of accurate gene expression measurements. In this paper, two CWT-based denoising methods have been implemented for microarray images using the standard MAP and LMMSE estimation criteria. The main strength of the proposed denoising methods is that unlike existing methods that are capable of processing each image separately, the pro-posed bivariate estimators incorporate the correlation information of the images as well as noise between the red and green channels. The experimental results show that the MAP estimator technique shows better denoising performance than other existing denoising techniques.REFERENCES[1]Y. Balagurunathan, E. R. Dougherty, Y. Chen, M.L.Bittner, and J. M.Trent, “Simulation of cDNA m i-croarrays via a parameterized random signal model,”J. Biomed. Opt., 2002, vol. 7, no. 3, pp. 507–523. [2] C. Boncelet, “Image noise models,” in Handbook ofImage and Video Processing, A. C. Bovik, Ed. New York: Academic, 2000.[3] D. Bozinov and J. Rahnenfuhrer, “Unsupervisedtechnique for robust target separation and analysis of DNA microarray spots through adaptive pixel clus-tering,” Bioinformatics, 2002, vol. 18, pp. 747–756.[4]T. Cai and B. Silverman, “Incorporating informationon neighboring coefficients into wavelet estima-tion,” Sank- hya: Indian J. Statist., 2001 vol. 63, pp.127–148.[5]S. W. Davies and D. A. Seale, “DNA microarraystochas tic model,” IEEE Trans. Nanobioscience, Sep.2005, vol. 4, no. 3, pp. 248–254. [6] D. L. Donoho and I. M. Johnstone, “Adapting tounknown smoothness via wavelet shrinkage,” J.Amer. Statist. Assoc., 1995,vol. 90, no. 432, pp.1200–1224.[7]J. M. Geoffrey, K. Do, and C. Ambroise, “AnalyzingMicroarray Gene Expression Data”,Hoboken, NJ: Wiley, 2004.[8]N. G. Kingsbury, “Complex wavelets for shift inva r-iance analysis and filtering of signals,” Appl. Com-put. Harmon. Anal., 2001, vol. 10, no. 3, pp. 234–253.[9]R. Lukac, K. N. Plataniotis, B. Smolka, and A. N.Venetsanopoulos, “A multichannel order-statistic technique for cDNA microarray image processing,”IEEE Trans. Nanobioscience, Dec.2004,vol. 3, no. 4, pp. 272–285.[10]S. Mallat, A Wavelet Tour of Signal Processing, 2nded. San Diego, CA: Academic, 1999.[11]L.Sendur and I. W. Selesnick, “Bivariate shrinkagefunctions for wavelet-based denoising exploiting in-terscale dependency,” IEEE Trans. Signal Process., Nov. 2002, vol. 50, no. 11, pp. 2744–2756.[12]L. Sendur and I. W. Selesnic k, “Bivariate shrinkagewith local variance estimation,” IEEE Signal Process.Lett., Dec. 2002, vol. 9, no. 12, pp. 438–441.[13]I. W. Selesnick, “Hilbert transform pairs of waveletbases,” IEEE Signal Process. Lett., Jun. 2001, vol. 8, no. 6, pp. 170–173.[14]I. W. Selesnick, R. G. Baraniuk, and N. G. Kings-bury, “The dual-tree complex wavelet transform,”IEEE Signal Processing Mag., June 2005, vol. 22, no.6, pp. 123–151.[15]E. P. Simoncelli and E. Adelson, “Noise removal viaBayesian wavelet coring,” in Proc. IEEE Int. Conf.Image Processing, Lusanne, Switzerland, 1996, vol.1, pp. 279–382.[16]Tamanna Howlader and YogendraP.Chaubey,”Noise Reduction of cDNA Microarray Images using Complex Wavelets”,IEEE transactions on Image Processing, August 2010, Vol. 19, No.8,pp.1953 -1967.[17]F. E. Turkheimer, D. C. Duke, L. B. Moran, and M.B. Graeber, “Wavelet analysis of gene expression(WAGE),” in Proc. IEEE Int. Symp. Biomedical Im-aging: Nano to Macro, 2004, vol. 2, pp. 1183–1186.[18]X. H. Wang, R. S. H. Istepanian, and Y. H. Song,“Microarray imageenhancement by denoising using stationary wavelet transform,” IEEE Trans. Nanobi-osci., Dec. 2003, vol. 2, no. 4, pp. 184–189.[19]Y. Yang, M. Buckley, S. Dudoit, and T. Speed,“Comparison of methods for image analysis on cDNA microarray data,” J. Comput. Graph. Statist., 2002, vol. 11, pp. 108–136.。
图像缩放算法综述
图像缩放算法综述作者:侯立华来源:《科学与财富》2014年第12期摘要:图像缩放是图像处理中的一项关键技术,多年来得到人们的高度重视,至今已经提出了大量的各种类型的算法。
文中将图像缩放算法分为插值方法,基于边缘的缩放算法,基于特定理论的缩放算法进行介绍和分析。
关键词:图像插值;图像边缘;弹性模型;小波变换;图像缩放1、引言2、图像插值图像插值是图像缩放中最常使用的方法,经典的插值方法有最邻近插值、双线性插值、双三次插值等。
最近邻插值算法[3]重构函数采用常量函数,最简单的图像比例缩小是水平方向和垂直方向的缩小比例相同,只需在原图像基础上,每行隔一个像素取一点,每隔一行进行操作,从而得到缩小后的图像。
双线性插值是利用了需要处理的原始图像像素点周围的四个像素点的相关性,重构函数采用双线性函数计算得出的。
双三次插值重构函数采用双三性函数,双三次插值算法较多,包括双三次多项式插值、双三次卷积插值、双三次样条插值、等[4]。
采用经典插值方法得到缩小后的目标图像会出现边缘模糊或锯齿等现象。
这是因为这些传统的图像缩放方法实质上是对源图像建立了连续的数学模型,然后按缩放要求进行重采样,得到缩放后的图像,缩放过程只使用了统一数学模型,忽略了边缘部分的高频信息损失的问题,因此得到的目标图像中物体边界层次模糊。
针对经典插值方法的不足,有的学者提出了曲面插值方法。
文献[5]提出了一种曲面拟合简化算法,以图像内任意相邻的可组成正方形的4个点为顶点组成的正方形范围拟合成双曲面,它的效果好于最近邻法、双线性插值法、双三次插值法等,但它参考的点数太少,忽略了图像的局部特征,当图像缩放比例比较大时,边缘处仍然存在少量的锯齿。
文献[6]提出一种基于带参数有理Coons曲面插值模型的图像缩放方法,其基本思想是首先将数字图像表示成带有形状参数的分片连续双三次有理Coons插值曲面,然后按缩放要求进行重新采样来实现图像的缩放,并通过调整参数的取值来获得满意的目标图像,所获得目标图像的效果要优于传统的插值法,但计算速度要稍慢。
小波变换在图像压缩中的应用(IJIGSP-V6-N2-7)
I. INTRODUCTION Memory and channel bandwidth are the prime constraints in image transmission and storage applications. In view of the growing energy requirements of wireless data services, the volume of multimedia data being transmitted over wireless channels may be reduced using various compression techniques, image compression entails transforming and organizing the data in an easy way of representation in which images of Copyright © 2014 MECS
Wavelet Transform Techniques for Image Compression – An Evaluation
S. Sridhar Faculty of ECE, Lendi Institute of Engineering & Technology Andhra Pradesh, INDIA sridhar.vskp@ P. Rajesh Kumar Associate Professor, Department of ECE, AU College of Engineering, Andhra University Andhra Pradesh, INDIA K.V.Ramanaiah Associate Professor, Department of
基于加权补丁对的人脸图像超分辨率(IJIGSP-V5-N3-1)
The ever increasing demand on surveillance cameras is quite visible nowadays. Some major users of such technologies are the banks, stores and parking lots. When using security cameras or cameras recording far distances, we usually face low resolution - low quality facial images. These images do not have sufficient information for recognition tasks or other usages and require a boosted upgrade in their resolution quality. Because there are always the high frequency details that carry the typical information used in processing techniques. This upgrade is performed with different automatic or manual process. Surveillance and monitoring systems like many other video based applications must extract and enhance small faces from a sequence of low-resolution frames [1], [2]. Direct interpolating of the input image is the simplest way to increase image resolution with algorithms such as cubic spline or nearest neighbor. But on the other hand the performance of direct interpolation is usually Copyright © 2013 MECS
图像缩放算法
图像缩放算法摘要:首先给出一个基本的图像缩放算法,然后一步一步的优化其速度和缩放质量;高质量的快速的图像缩放全文分为:上篇近邻取样插值和其速度优化中篇二次线性插值和三次卷积插值下篇三次线性插值和MipMap链正文:为了便于讨论,这里只处理32bit的ARGB颜色;代码使用C++;涉及到汇编优化的时候假定为x86平台;使用的编译器为vc2005;为了代码的可读性,没有加入异常处理代码;测试使用的CPU为AMD64x2 4200+(2.37G) 和 Intel Core2 4400(2.00G);速度测试说明:只测试内存数据到内存数据的缩放测试图片都是800*600缩放到1024*768; fps表示每秒钟的帧数,值越大表示函数越快//////////////////////////////////////////////////////////////////////// //////////Windows GDI相关函数参考速度://====================================================================== ========// BitBlt 544.7 fps //is copy 800*600 to 800*600// BitBlt 331.6 fps //is copy 1024*1024 to 1024*1024// StretchBlt 232.7 fps //is zoom 800*600 to 1024*1024//////////////////////////////////////////////////////////////////////// ////////A: 首先定义图像数据结构:#define asm __asmtypedef unsigned char TUInt8; // [0..255]struct TARGB32 //32 bit color{TUInt8 B,G,R,A; // A is alpha};struct TPicRegion //一块颜色数据区的描述,便于参数传递{TARGB32* pdata; //颜色数据首地址long byte_width; //一行数据的物理宽度(字节宽度);//abs(byte_width)有可能大于等于width*sizeof(TARGB32);long width; //像素宽度long height; //像素高度};//那么访问一个点的函数可以写为:inline TARGB32& Pixels(const TPicRegion& pic,const long x,const long y) {return ( (TARGB32*)((TUInt8*)pic.pdata+pic.byte_width*y) )[x];}B: 缩放原理和公式图示:缩放后图片原图片(宽DW,高DH) (宽SW,高SH)(Sx-0)/(SW-0)=(Dx-0)/(DW-0) (Sy-0)/(SH-0)=(Dy-0)/(DH-0)=> Sx=Dx*SW/DW Sy=Dy*SH/DHC: 缩放算法的一个参考实现//给出一个最简单的缩放函数(插值方式为近邻取样,而且我“尽力”把它写得慢一些了:D)//Src.PColorData指向源数据区,Dst.PColorData指向目的数据区//函数将大小为Src.Width*Src.Height的图片缩放到Dst.Width*Dst.Height的区域中void PicZoom0(const TPicRegion& Dst,const TPicRegion& Src){if ( (0==Dst.width)||(0==Dst.height)||(0==Src.width)||(0==Src.height)) return;for (long x=0;x<Dst.width;++x){for (long y=0;y<Dst.height;++y){long srcx=(x*Src.width/Dst.width);long srcy=(y*Src.height/Dst.height);Pixels(Dst,x,y)=Pixels(Src,srcx,srcy);}}}//////////////////////////////////////////////////////////////////////// //////////速度测试://====================================================================== ========// PicZoom0 19.4 fps//////////////////////////////////////////////////////////////////////// ////////D: 优化PicZoom0函数a.PicZoom0函数并没有按照颜色数据在内存中的排列顺序读写(内部循环递增y行索引),将造成CPU缓存预读失败和内存颠簸导致巨大的性能损失,(很多硬件都有这种特性,包括缓存、内存、显存、硬盘等,优化顺序访问,随机访问时会造成巨大的性能损失)所以先交换x,y循环的顺序:void PicZoom1(const TPicRegion& Dst,const TPicRegion& Src){if ( (0==Dst.width)||(0==Dst.height)||(0==Src.width)||(0==Src.height)) return;for (long y=0;y<Dst.height;++y){for (long x=0;x<Dst.width;++x){long srcx=(x*Src.width/Dst.width);long srcy=(y*Src.height/Dst.height);Pixels(Dst,x,y)=Pixels(Src,srcx,srcy);}}}//////////////////////////////////////////////////////////////////////// //////////速度测试://====================================================================== ========// PicZoom1 30.1 fps//////////////////////////////////////////////////////////////////////// ////////b.“(x*Src.Width/Dst.Width)”表达式中有一个除法运算,它属于很慢的操作(比一般的加减运算慢几十倍!),使用定点数的方法来优化它;void PicZoom2(const TPicRegion& Dst,const TPicRegion& Src){if ( (0==Dst.width)||(0==Dst.height)||(0==Src.width)||(0==Src.height)) return;//函数能够处理的最大图片尺寸65536*65536unsigned long xrIntFloat_16=(Src.width<<16)/Dst.width+1; //16.16格式定点数unsigned long yrIntFloat_16=(Src.height<<16)/Dst.height+1; //16.16格式定点数//可证明: (Dst.width-1)*xrIntFloat_16<Src.width成立for (unsigned long y=0;y<Dst.height;++y){for (unsigned long x=0;x<Dst.width;++x){unsigned long srcx=(x*xrIntFloat_16)>>16;unsigned long srcy=(y*yrIntFloat_16)>>16;Pixels(Dst,x,y)=Pixels(Src,srcx,srcy);}}}//////////////////////////////////////////////////////////////////////// //////////速度测试://====================================================================== ========// PicZoom2 185.8 fps//////////////////////////////////////////////////////////////////////// ////////c. 在x的循环中y一直不变,那么可以提前计算与y相关的值; 1.可以发现srcy的值和x变量无关,可以提前到x轴循环之前;2.展开Pixels函数,优化与y相关的指针计算;void PicZoom3(const TPicRegion& Dst,const TPicRegion& Src){if ( (0==Dst.width)||(0==Dst.height)||(0==Src.width)||(0==Src.height)) return;unsigned long xrIntFloat_16=(Src.width<<16)/Dst.width+1;unsigned long yrIntFloat_16=(Src.height<<16)/Dst.height+1;unsigned long dst_width=Dst.width;TARGB32* pDstLine=Dst.pdata;unsigned long srcy_16=0;for (unsigned long y=0;y<Dst.height;++y){TARGB32*pSrcLine=((TARGB32*)((TUInt8*)Src.pdata+Src.byte_width*(srcy_16>>16))); unsigned long srcx_16=0;for (unsigned long x=0;x<dst_width;++x){pDstLine[x]=pSrcLine[srcx_16>>16];srcx_16+=xrIntFloat_16;}srcy_16+=yrIntFloat_16;((TUInt8*&)pDstLine)+=Dst.byte_width;}}//////////////////////////////////////////////////////////////////////// //////////速度测试://====================================================================== ========// PicZoom3 414.4 fps//////////////////////////////////////////////////////////////////////// ////////d.定点数优化使函数能够处理的最大图片尺寸和缩放结果(肉眼不可察觉的误差)受到了一定的影响,这里给出一个使用浮点运算的版本,可以在有这种需求的场合使用:void PicZoom3_float(const TPicRegion& Dst,const TPicRegion& Src){//注意: 该函数需要FPU支持if ( (0==Dst.width)||(0==Dst.height)||(0==Src.width)||(0==Src.height)) return;double xrFloat=1.000000001/((double)Dst.width/Src.width);double yrFloat=1.000000001/((double)Dst.height/Src.height);unsigned short RC_Old;unsigned short RC_Edit;asm //设置FPU的取整方式为了直接使用fist浮点指令{FNSTCW RC_Old // 保存协处理器控制字,用来恢复FNSTCW RC_Edit // 保存协处理器控制字,用来修改FWAITOR RC_Edit, 0x0F00 // 改为 RC=11 使FPU向零取整FLDCW RC_Edit // 载入协处理器控制字,RC场已经修改}unsigned long dst_width=Dst.width;TARGB32* pDstLine=Dst.pdata;double srcy=0;for (unsigned long y=0;y<Dst.height;++y){TARGB32* pSrcLine=((TARGB32*)((TUInt8*)Src.pdata+Src.byte_width* ((long)srcy)));/**//*double srcx=0;for (unsigned long x=0;x<dst_width;++x){pDstLine[x]=pSrcLine[(unsigned long)srcx];//因为默认的浮点取整是一个很慢//的操作! 所以才使用了直接操作FPU的内联汇编代码。
一种低复杂度的数字图像对比度增强算法(IJIGSP-V10-N2-7)
I.J. Image, Graphics and Signal Processing, 2018, 2, 60-67Published Online February 2018 in MECS (/)DOI: 10.5815/ijigsp.2018.02.07A Low-Complexity Algorithm for ContrastEnhancement of Digital ImagesZohair Al-AmeenDepartment of Computer Science, College of Computer Science and Mathematics,University of Mosul, Nineveh, IraqEmail: qizohair@Zaman Awni HasanDepartment of General Education, College of Education and Languages,Lebanese French University, Erbil, Kurdistan Region, IraqEmail: zaman.iphone@mail.ruReceived: 31 October 2017; Accepted: 10 January 2018; Published: 08 February 2018Abstract—As known, the contrast is a highly important feature by which the visual quality of digital images can be judged as adequate or poor. Hence, many methods exist for contrast enhancement, where the complexity of those methods usually varies due to the utilization of different concepts. In this article, a simple yet efficient algorithm is introduced for contrast enhancement of digital images. The proposed algorithm consists of four distinct stages: In the first stage, the hyperbolic sine function is applied to provide a simple contrast modification. In the second stage, a modified power-law function is utilized to control the amount of contrast adjustment. In the third stage, the standard sigmoid function is used to remap the image pixels into an “S” shape, which can provide further contrast enhancement. In the final stage, a contrast stretching function is applied to remap the image pixels into their natural dynamic range. The performed computer experiments on different low-contrast images demonstrated the efficiency of the proposed algorithm in processing synthetic and real degraded images, as it provided better and clearer results when compared to several existing contrast enhancement algorithms. To end with, the proposed algorithm can be used as a contrast processing step in many image-related applications.Index Terms—Contrast enhancement, Image processing, Low-complexity algorithm, Low-contrast.I.I NTRODUCTIONOver the last decades, substantial progress has been made in the fields of digital image processing and computer vision by both professionals and researchers [23]. Contrast enhancement is an important image processing field that plays an essential role in improving the visible quality for a variety of image-related applications [4]. Moreover, it is considered an important processing step in different scientific applications [7]. The insufficient contrast in digital images can occur due to many reasons, including the deficient expertise of the operator and the use of an inefficient device for image acquisition [1]. Commonly, the contrast is generated due to variance in luminance between two adjacent surfaces. Accordingly, the contrast of a given image can be determined via the intensity difference of an object with other objects. Thus, if the image intensities have a restricted distribution within a limited range, the contrast of the observed image would become low and its details would be obscured.The low-contrast effect reduces the visual quality of an image and thus, it should be handled properly to provide acceptable quality for digital images [9]. Hence, it is desired to redistribute the intensities of a given image to the entire dynamic range in order to improve its contrast and provide an adequate representation for its information [10]. Generally, the methods for contrast enhancement of can be categorized into direct [2, 3] and indirect [5, 6] methods. In the direct methods, a certain contrast term is used to define the image contrast. Since a digital image contains simple and complex patterns, using such contrast terms may fail to measure the contrast in a variety of images [31]. On the contrary, indirect methods try to improve the image contrast by redistributing the probability density. This means that the intensities of a given image can be reallocated within the natural range without using a certain contrast term [1].Most of these methods are implemented either in the spatial domain or the frequency domain. Accordingly, the image is processed as it is in the spatial domain, whereas in the frequency domain, the image is first transformed to its frequency version, then the processing occurs; after that, an inverse transformation is applied to view the image in the spatial domain [20]. Histogram-based methods for contrast enhancement are the most famous indirect methods due to straightforward implementation [8]. Despite the major advantages of these indirect methods, many of such tend to produce undesirable degradations (e.g. under-saturation, over-saturation) to the processed images [21]. Hence, a low-complexityalgorithm is introduced in this article to process low-contrast images rapidly and efficiently without introducing any undesirable degradations. The proposed algorithm is developed experimentally and consists of 4 distinct steps, for which each step provides a positive contribution to the enhancement process. In addition, the enhancement ability of the proposed algorithm is controlled using a single parameter. The developed algorithm is evaluated by a dataset of synthetic and real degraded low-contrast images collected from various internet websites. The synthetic degraded images are used for comparison purposes, while the real degraded images are used for experimental purposes [32]. Moreover, the quality of the obtained results is measured using two reliable image quality assessment (IQA) metrics. Likewise, the proposed algorithm is compared with three well-known contrast enhancement methods. To end with, most of the available contrast enhancement methods employ the concept of histogram equalization. In addition, most of the available contrast enhancement methods that provide acceptable results have a complex structure with a high number of calculations. However, the proposed algorithm has a simple structure and does not utilize the concept of histogram equalization. To test the processing ability of the proposed algorithm, various computer experiments on different low-contrast images are performed. The rest of the article is ordered as follows: in Section II, an abridged review of literature is delivered. In Section III, the proposed algorithm is explained in detail. In Section IV, the results and their related discussions are provided. Finally, a concise conclusion is given in Section V.II.R ELATED W ORKSIn this section, various contrast enhancement methods are addressed to highlight some of the important concepts that have been utilized previously. In view of that, the dynamic histogram equalization [24] is an enhancement technique that works by partitioning the histogram of the input image depending on local minima and allocates certain gray-level ranges for every partition before processing them independently. The aforementioned partitions undergo further tests to avoid having dominating partitions. Another method of interest is fused logarithmic transform [25], as its enhancement is achieved by fusing the degraded image and its logarithmic counterparts.In addition, the intensity surface stretching technique [26] processes an image by stretching its intensity surface to the maximum range with consideration to the distances between the pristine intensity surface as well as the upper and lower intensity surfaces, which are created automatically from the pristine intensity surface by calculating the gamma transform and Gaussian smoothing. Moreover, the algorithm proposed in [27] processes an image using the theory of partitioned iterated function system (PIFS). The PIFS is utilized to generate a low-pass counterpart of the input image. The enhanced image is generated by adding the difference of the input image and its low-pass counterpart to the input image itself. Furthermore, the Gaussian mixture modeling based algorithm [28] processes an image by modeling its gray-level distribution to generate gray-level intervals. The resulting image is created by changing the gray-level of pixels in each determined interval to the suitable output gray-level interval in relation to the cumulative distribution function and the dominant Gaussian element of the input interval.Another interesting method is the spatial entropy-based enhancement [29], as it distributes the spatial positions of gray-levels of an image rather than gray-level distribution. The spatial distribution is calculated for each gray-level by a histogram of spatial positions for all pixels with the same gray-level. From the spatial distributions of image gray-levels, the entropy measures are computed to generate a distribution function, which is also mapped to another distribution function to attain the final enhancement. To end with, the method introduced in [30] works by iteratively solving a nonlinear diffusion equation. Through the process of diffusion, surround suppression is included in the conductance function to improve the diffusive strength in certain areas of the image. As seen from the above-reviewed methods, various low and high intricacy concepts have been utilized for the purpose of contrast enhancement. Thus, developing a new algorithm that utilizes a simple concept and achieves acceptable enhancement is desirable in many computer vision and image processing applications.III.P ROPOSED A LGORITHMFig.1. The framework of the proposed algorithm.The proposed algorithm is developed experimentally with intention of providing an adequate enhancement for images with poor contrast. The framework of the proposed algorithm is illustrated as in Fig. 1.The proposed algorithm starts by applying the hyperbolic sine function as an initial processing stage to provide a simple contrast modification. This function can be described as follows [11]:2x xe e s --=(1)where, (x ) is the input low-contrast image, (s ) is the resulting image from the hyperbolic sine function. Then, the result of the previous stage is processed by a modified version of the famous power-law function. The standard power-law function can be written as follows [12]:p c s λ=*(2)where, (c ) is a scalar that controls the brightness of the power-law function, (λ) is a scalar that controls the enhancement of contrast. The values of these scalars must fulfill (c , λ > 0), where a higher (c ) value leads to a brighter result and a higher (λ) value leads to a less bright and contrast improved result. Thus, the above standard function is modified by removing the scalar (c ) because it can lead to an undesirable increase in the brightness of the processed image. Hence, the modified power-law function is written as follows:y s λ=(3)where, (y ) is the resulting image from the modified power-law function. Afterwards, the standard sigmoid function is utilized to remap the image pixels in an “S” shape, which can provide further contrast enhancement. The used sigmoid function can be written as follows [13]:11yw e -=+ (4)where, (w ) is the resulting image from the standard sigmoid function. As a final stage, a contrast stretching function is applied to remap the image pixels into their natural dynamic range [22]. The used stretching function can be described as follows [14]:()()()min max min w w f w w -=-(5)where, min and max are the minimum and maximum pixel values, respectively. ( f ) is the final result of the proposed algorithm. Finally, the benefits of this algorithm are fast processing speed, low computation cost, and artifact-free images with acceptable quality results.IV. R ESULTS AND D ISCUSSIONIn this section, the essential computer experiments and their related discussions are provided to validate the processing ability of the proposed algorithm. To performproper experiments, real-degraded images were used for experimental purposes, and synthetic-degraded images were used for comparison purposes. The dataset of this study was collected from different imaging databases across the internet. Regarding the comparable methods, several contemporary and reliable methods were chosen, in which the proposed algorithm was compared with three of such methods namely, successive mean quantization transform (SMQT) [15], gradient distribution specification (GDS) [16], and exposure based sub image histogram equalization (ESIHE) [17].Regarding the used IQA metrics, two well-known full-reference IQA metrics of universal image quality index (UIQI) [18] and structural similarity index (SSIM) [19] were used to measure the quality of the results of comparisons. The results of these metrics are constant numbers, in which values near 1 indicate high-quality results and values near 0 indicate low-quality results. The experimental results obtained from processing various real-degraded grayscale images are shown in Fig. 2 – Fig. 4. The results of the performed comparisons can be seen in Fig. 5 and Fig. 6. The recorded accuracy by the UIQI and SSIM metrics are provided in Table 1, Fig. 7 and Fig. 8. From the obtained experimental results in Fig. 2 – Fig. 4, it can be seen that the proposed algorithm provided visually pleasing results. Moreover, the recovered images show natural brightness, acceptable contrast with no visible flaws. However, the value of λ dif fers from one image to another due to the noticeable differences in the nature of the used images and the variance in contrast levels for each processed image.From the obtain comparison results in Fig. 5 – Fig. 8 and Table 1, it is evident that the proposed algorithm performed the best in terms of recorded accuracy and perceived quality, as it recorded the best UIQI and SSIM scores, as well as, it provided clear and unblemished results. This is significant because the proposed algorithm has a simple structure with a non-iterative nature and utilizes few calculations to achieve its task. Regarding the SMQT method, it provided very good performances especially when the contrast of the processed image was severely reduced. However, its high computation and iterative natures made it slow in producing the desired results. Moreover, this method tends to increase the darkness of dim areas in the processed images. Such limitations can lead to unclear results, especially for images with many dim areas.Regarding the GDS method, it provided moderate contrast enhancement, yet the low-contrast effect is still visible in the processed images. In addition, this method is somewhat slow due to its high computations utilization. Regarding the ESIHE method, it provided good performance when the processed image had minor contrast reduction. However, it provided poor performance when the processed image had major contrast reduction. Accordingly, the output of this method has low brightness and poor contrast. Such artifacts can limit the use of this method in certain image processing applications. Finally, developing an efficient, yet uncomplicated algorithm for contrast enhancement is achallenging and significant task. However, this task is clearly achieved successfully, as the proposed algorithm provided visually pleasing results with no visible artifacts and outperformed the comparable algorithms in terms of visual quality and scored accuracy.Fig.2. The obtained results of the proposed algorithm. (a1 – c1): real-degraded images; (a2 – c2) from left to right: images recovered by the proposed algorithm with λ=1.1, λ=1.6, and λ=0.9, respectively.Fig.3. The obtained results of the proposed algorithm. (a1 – c1): real-degraded images; (a2 – c2) from left to right: images re covered by the proposed algorithm with λ=0.5, λ=0.4, and λ=0.25, respectively.images recovered by the proposed algorithm with λ=4, λ=1.1, and λ=1.5, respectively.(c) SMQT; (d) GDS; (e) ESIHE; (f) proposed algorithm with λ=1.1;Fig.6. The results of the achieved comparison. (a) True image; (b) Contrast reduced image by 80%; images from (c – f) are recovered by:(c) SMQT; (d) GDS; (e) ESIHE; (f) proposed algorithm with λ=1.5;Table 1. The recorded accuracy of the used IQA metrics for the comparable methods.Fig.7. The graphical chart for the obtained accuracy results by the UIQI metric.Fig.8. The graphical chart for the obtained accuracy results by the SSIM metric.V. C ONCLUSIONIn this article, an innovative algorithm for contrast enhancement of digital images is introduced. The proposed algorithm utilizes four distinct functions of hyperbolic sine, modified power-law, sigmoid and contrast stretching to achieve the desired enhancement. The obtained results were benchmarked with synthetic and real degraded images and compared with the three well-known contrast enhancement methods of SMQT, GDS, and ESIHE. Furthermore, the accuracy of the obtained results was measured using two well-known metrics of UIQI and SSIM. From the obtained results, it can be seen the proposed algorithm provided satisfying results and outperformed the comparable methods since it scored the best in terms of visual quality and IQA metrics. Accordingly, the proposed algorithm provided a natural appearance with no visible errors to the processed images, wherein such acceptable results can highly support the validity of the proposed algorithm. Finally, the use of simple methods for contrast enhancement is desirable in many image-related applications.A CKNOWLEDGMENTThe authors wish to thank the respectable reviewers and editors for their helpful comments.R EFERENCES[1] T. Arici, S. Dikbas and Y. Altunbasak, "A histogrammodification framework and its application for image contrast enhancement", IEEE Transactions on Image Processing , vol. 18, no. 9, pp. 1921-1935, 2009.[2] A. Beghdadi and A. le Negrate, "Contrast enhancementtechnique based on local detection of edges", Computer Vision, Graphics, and Image Processing , vol. 46, no. 2, pp. 162-174, 1989.[3] H. Cheng and H. Xu, "A novel fuzzy logic approach tocontrast enhancement", Pattern Recognition , vol. 33, no. 5, pp. 809-819, 2000.[4] S. Huang, F. Cheng and Y. Chiu, "Efficient contrastenhancement using adaptive gamma correction with weighting distribution", IEEE Transactions on Image Processing , vol. 22, no. 3, pp. 1032-1041, 2013.[5] R. Sherrier and G. Johnson, "Regionally adaptivehistogram equalization of the chest", IEEE Transactions on Medical Imaging , vol. 6, no. 1, pp. 1-7, 1987.[6] A. Polesel, G. Ramponi and V. Mathews, "Imageenhancement via adaptive unsharp masking", IEEE Transactions on Image Processing , vol. 9, no. 3, pp. 505-510, 2000.[7] Z. Al-Ameen, G. Sulong and M. Johar, "Employing asuitable contrast enhancement technique as a pre-restoration adjustment phase for computed tomography medical images", International Journal of Bio-Science and Bio-Technology , vol. 5, no. 1, pp. 73-80, 2013.[8] Y. Kim, "Contrast enhancement using brightnesspreserving bi-histogram equalization", IEEE Transactions on Consumer Electronics , vol. 43, no. 1, pp. 1-8, 1997. [9] M. Mahamdioua and M. Benmohammed, "New mean-variance gamma method for automatic gamma correction", International Journal of Image, Graphics and Signal Processing , vol. 9, no. 3, pp. 41-54, 2017.[10] A. Raju, G. Dwarakish and D. Reddy, "A comparativeanalysis of histogram equalization based techniques for contrast enhancement and brightness preserving", International Journal of Signal Processing, Image Processing and Pattern Recognition , vol. 6, no. 5, pp. 353-366, 2013.[11] M. Abramowitz and I. Stegun, "Hyperbolic Functions". InHandbook of Mathematical Functions with Formulas, Graphs, and Mathematical Tables , 9th printing. New York: Dover, pp. 83-86, 1972.[12] C. Tsai, "Adaptive local power-law transformation forcolor image enhancement", Applied Mathematics & Information Sciences , vol. 7, no. 5, pp. 2019-2026, 2013. [13] N. Hassan and N. Akamatsu, "A new approach forcontrast enhancement using sigmoid function", International Arab Journal of Information Technology , vol. 1, no. 2, pp. 221-225, 2004.[14] A. Łoza, D. Bull, P. Hill and A. Achim, "Automaticcontrast enhancement of low-light images based on local statistics of wavelet coefficients", Digital Signal Processing , vol. 23, no. 6, pp. 1856-1866, 2013.[15] M. Nilsson, M. Dahl and I. Claesson, "The successivemean quantization transform", IEEE International Conference on Acoustics, Speech, and Signal Processing ; 23-23 March; Philadelphia, USA, pp. 429-432, 2005.[16] Y. Gong and I. Sbalzarini, "Image enhancement bygradient distribution specification", Asian Conference on Computer Vision (ACCV 2014), pp. 47-62, 2014.[17] K. Singh and R. Kapoor, "Image enhancement usingexposure based sub image histogram equalization", Pattern Recognition Letters , vol. 36, pp. 10-14, 2014.[18]Z. Wang and A. Bovik, "A universal image qualityindex", IEEE Signal Processing Letters, vol. 9, no. 3, pp.81-84, 2002.[19]Z. Wang, A. Bovik, H. Sheikh and E. Simoncelli, "Imagequality assessment: from error visibility to structural similarity". IEEE Transactions on Image Processing, vol.13, no. 4, pp. 600-612, 2004.[20]P. Mamoria and D. Raj, "Comparison of mamdani fuzzyinference system for multiple membership functions", International Journal of Image, Graphics and Signal Processing, vol. 8, no. 9, pp. 26-30, 2016.[21] C. Ooi and N. Mat Isa, "Adaptive contrast enhancementmethods with brightness preserving", IEEE Transactions on Consumer Electronics, vol. 56, no. 4, pp. 2543-2551, 2010.[22]Z. Al-Ameen, D. Mohamad, M. Rahim and G. Sulong,"Restoring degraded astronomy images using a combination of denoising and deblurring techniques", International Journal of Signal Processing, Image Processing and Pattern Recognition, vol. 5, no. 1, pp. 1-11, 2012.[23]P. Gupta and K. Pahwa, "Enhancing colors of a digitalimage using clock algorithm", International Journal of Image, Graphics and Signal Processing, vol. 7, no. 11, pp.9-15, 2015.[24]M. Abdullah-Al-Wadud, M. Kabir, M. Dewan and O.Chae, "A dynamic histogram equalization for image contrast enhancement", IEEE Transactions on Consumer Electronics, vol. 53, no. 2, pp. 593-600, 2007.[25]H. Le and H. Li, "Fused logarithmic transform forcontrast enhancement", Electronics Letters, vol. 44, no. 1, pp. 19-20, 2008.[26] D. Kim and E. Cha, "Intensity surface stretchingtechnique for contrast enhancement of digital photography", Multidimensional Systems and Signal Processing, vol. 20, no. 1, pp. 81-95, 2008.[27]T. Economopoulos, P. Asvestas and G. Matsopoulos,"Contrast enhancement of images using partitioned iterated function systems", Image and Vision Computing, vol. 28, no. 1, pp. 45-54, 2010.[28]T. Celik and T. Tjahjadi, "Automatic image equalizationand contrast enhancement using Gaussian mixture modeling", IEEE Transactions on Image Processing, vol.21, no. 1, pp. 145-156, 2012.[29]T. Celik, "Spatial entropy-based global and local imagecontrast enhancement", IEEE Transactions on Image Processing, vol. 23, no. 12, pp. 5298-5308, 2014. [30]Z. Liang, W. Liu and R. Yao, "Contrast enhancement bynonlinear diffusion filtering", IEEE Transactions on Image Processing, vol. 25, no. 2, pp. 673-686, 2016. [31]J. Tang, X. Liu and Q. Sun, "A direct image contrastenhancement algorithm in the wavelet domain for screening mammograms", IEEE Journal of Selected Topics in Signal Processing, vol. 3, no. 1, pp. 74-80, 2009.[32]S. Narasimhan and S. Nayar, "Contrast restoration ofweather degraded images", IEEE Transactions on Pattern Analysis and Machine Intelligence, vol. 25, no. 6, pp.713-724, 2003.Authors’ ProfilesZohair Al-Ameen was born in 1985. Hereceived his BSc degree in ComputerScience from the University of Mosul in2008. Then, he received his MSc and PhDdegrees in Computer Science from theTechnological University of Malaysia in2011 and 2015, respectively. He wasawarded the best student award owing tothe outstanding performance in his PhD studies. His research interests include algorithms design, artificial intelligence, computer forensics, computer vision, and digital image processing. Currently, he is a full-time lecturer at the Department of Computer Science, College of Computer Science and Mathematics, University of Mosul. Finally, he has authored many articles which are published in international journals of high repute.Zaman Awni Hasan studied her Bachelorof Education (Information Technology) atthe Department of General Education,Lebanese French University. She ismajoring in information technology,specifically in digital image processing.She is interested in pursuing a career inthe teaching field. Her current topics ofinterest include computer vision, digital image processing, educational technologies, educational information technology, educational techniques, e-learning, multimedia technology in education and research methodology.How to cite this paper: Zohair Al-Ameen, Zaman Awni Hasan," A Low-Complexity Algorithm for Contrast Enhancement of Digital Images", International Journal of Image, Graphics and Signal Processing(IJIGSP), Vol.10, No.2, pp.60-67, 2018.DOI: 10.5815/ijigsp.2018.02.07。
JPEG图片的缩放处理方法
JPEG图片的缩放处理方法
唐志英
【期刊名称】《河北工程技术高等专科学校学报》
【年(卷),期】2008(000)003
【摘要】图片缩放的处理方法有很多种,常规的有抽点法、平均法、双线性法.文中重点讨论了抽点法、平均法在视频MP3中的实现方法,并对使用这三种方法对图片处理后的效果进行了比较.
【总页数】4页(P56-59)
【作者】唐志英
【作者单位】江苏省惠山职教中心校,江苏,惠山,214187
【正文语种】中文
【中图分类】TP391.41
【相关文献】
1.Gif动态图片怎样缩放 [J], JY
2.忽视缩放浏览器图片自动放大指南 [J], 青山漫步
3.JPEG的末日就要来到?——图片压缩格式JPEG 2000 [J], 吴朝相
4.图片渐小终不悔——图片压缩软件JPEG Optimizer [J], ;
5.人靓身材好图片自出众 JPEG Opt超级图片优化专家 [J], 杨特
因版权原因,仅展示原文概要,查看原文内容请购买。
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
I.J. Image, Graphics and Signal Processing, 2013, 5, 55-62Published Online April 2013 in MECS (/)DOI: 10.5815/ijigsp.2013.05.07A Comparative Analysis of Image ScalingAlgorithmsChetan SureshDepartment of Electrical and Electronics Engineering, BITS PilaniPilani - 333031, Rajasthan, IndiaE-mail: shivchetan@Sanjay Singh, Ravi Saini, Anil K SainiScientist, IC Design Group,CSIR – Central Electronics Engineering Research Institute (CSIR-CEERI)Pilani – 333031, Rajasthan, IndiaAbstract—Image scaling, fundamental task of numerous image processing and computer vision applications, is the process of resizing an image by pixel interpolation. Image scaling leads to a number of undesirable image artifacts such as aliasing, blurring and moiré. However, with an increase in the number of pixels considered for interpolation, the image quality improves. This poses a quality-time trade off in which high quality output must often be compromised in the interest of computation complexity. This paper presents a comprehensive study and comparison of different image scaling algorithms. The performance of the scaling algorithms has been reviewed on the basis of number of computations involved and image quality. The search table modification to the bicubic image scaling algorithm greatly reduces the computational load by avoiding massive cubic and floating point operations without significantly losing image quality.Index Terms—Image Scaling, Nearest-neighbour, Bilinear, Bicubic, Lanczos, Modified BicubicI.I NTRODUCTIONImage scaling is a geometric transformation used to resize digital images and finds widespread use in computer graphics, medical image processing, military surveillance, and quality control [1]. It plays a key role in many applications [2] including pyramid construction [3]-[4], super-sampling, multi-grid solutions [5], and geometric normalization [6].In surveillance-based applications, images have to be monitored at a high frame rate. Since, the images need not be of the same size, image scaling is necessary for comparison and manipulation of images. However, image scaling is a computationally intensive process due to the convolution operation, which is necessary to band-limit the discrete input and thereby diminishes undesirable aliasing artifacts [2].Various image scaling algorithms are available in literature and employ different interpolation techniques to the same input image. Some of the common interpolation algorithms are the nearest neighbour, bilinear [7], and bicubic [8]-[9]. Lanczos algorithm utilizes the 3-lobed Lanczos window function to implement interpolation [10].There are many other higher order interpolators which take more surrounding pixels into consideration, and thus also require more computations. These algorithms include spline [11] and sinc interpolation [12], and retain the most of image details after an interpolation. They are extremely useful when the image requires multiple rotations/distortions in separate steps. However, for single-step enlargements or rotations, these higher-order algorithms provide diminishing visual improvement and processing time increases significantly.Novel interpolation algorithms have also been proposed such as auto-regression based method [13], fuzzy area-based scaling [14], interpolation using classification and stitching [15], isophote-based interpolation [16], and even interpolation scheme combined with Artificial Neural Networks [17]. Although these algorithms perform well, they require a lengthy processing time due to their complexity. This is intolerable for real-time image scaling in video surveillance system. Hence, these algorithms have not been considered for the comparative analysis in this paper.In this paper, firstly, image interpolation algorithms are classified and reviewed; then evaluation and comparison of five image interpolation algorithms are discussed in depth based on the reason that evaluation of image interpolation is essential in the aspect of designing a real-time video surveillance system. Analysis results of the five interpolation algorithms are summarized and presented.II.I MAGE S CALINGImage scaling is obtained by performing interpolation over one or two directions to approximate a pixel’s colour and intensity based on the values at neighbouringpixels. More the adjacent pixels used for interpolation, better the quality of interpolated output image. Digital image interpolation is the process of generating a continuous intensity surface from discrete image data samples. Generally, almost every geometric transformation like translating, rotating, scaling, and warping requires interpolation to be performed on an image [18]. Such transformations are essential to any commercial digital image processing software. The perceived quality of the interpolated images is affected by several issues such as sharpness of edges, freedom from artifacts and reconstruction of high frequency details [18].Interpolation algorithms attempt to generate continuous data from a set of discrete data samples through an interpolation function. These interpolation methods aim to minimize the visual defects arising from the inevitable resampling error and improve the quality of re-sampled images [19]. Interpolation function is performed by convolution operation which involves a large number of addition and multiplication operations. Hence, a trade-off is required between computation complexity and quality of the scaled image.Based on the content awareness of the algorithm, image scaling algorithms can be classified as Adaptive image scaling and Non-adaptive image scaling. Adaptive image scaling algorithms modify their interpolation technique based on the image content being a smooth texture [20] or a sharp edge [21]-[22]. As the interpolation method changes in real-time, these algorithms are complex and computationally intensive. They find widespread use in image editing software as they ensure a high quality scaled image. As the focus is on analysing image scaling algorithms for real-time applications, these algorithms are beyond the scope of the paper.Non-adaptive image scaling algorithms like nearest neighbour, bilinear, bicubic and Lanczos algorithms have a fixed interpolation method irrespective of the image content.III. C OMPARATIVE A NALYSIS OF I MAGE S CALINGA LGORITHMS This section discusses the Non-adaptive Image scaling algorithms like nearest neighbour, bilinear, bicubic, modified bicubic, and Lanczos. Let P(x,y) represent the pixel in input image of MxN dimensions and U(i,j) represents the pixel in scaled/resized output image of size M’xN’. Let T be the transformation used for scaling. The each pixel of output image is computed by applying the transformation T on input image pixels as shown inFig. 1.Figure 1. Image scaling procedureA. N EAREST N EIGHBOUR I MAGE S CALINGThe simplest image interpolation method is to select the value of the nearest input image pixel and assigning the same value to scaled image pixel. The nearest neighbour algorithm (Fig. 2) selects the value of the nearest known pixel and does not consider the values of other neighbouring pixels, yielding a piecewise constant function [23].For nearest neighbour algorithm the level of complexity is low leading to a fast computation time. But the scaled image quality is low and high aliasingeffect is observed.Figure 2. Nearest neighbour image scaling algorithmB. B ILINEAR I MAGE S CALINGAnother simple interpolation method is linear interpolation, a slight improvement over the nearest neighbour interpolation algorithm. In linear interpolation, the interpolated value is computed based on the weighted average of two data points. The weights are inversely proportional to the distance of the end points from the interpolated data point.Bilinear interpolation algorithm [7] performs linear interpolation in one direction followed by linear interpolation of the interpolated values in the other direction. The algorithm uses 4 diagonal pixels surrounding the corresponding source image pixel for interpolation (Fig. 3). It computes a weighted average depending on the nearness and brightness of the 4 diagonal pixels and assigns that value to the pixel in the output image.Figure 3. Bilinear image scaling algorithmBilinear offers considerable improvement in image quality with a slightly increased complexity. The aliasing effect is reduced though blurring is observed. C. B ICUBIC I MAGE S CALINGBicubic interpolation algorithm [8]-[9] performs cubic interpolation in one direction followed by cubic interpolation of the interpolated values in the otherdirection (Fig. 4).Figure 4. Bicubic image scaling algorithmThe bicubic interpolation approximates a sinc interpolation by using cubic polynomial waveforms instead of linear waveforms when computing an output pixel value. The algorithm uses 16 nearest pixelssurrounding the closest corresponding pixel in the source image for interpolation.Bicubic offers high scaled image quality at the cost of considerably high complexity. Edge halo effect is observed though aliasing and blurring are reduced. D. L ANCZOS I MAGE S CALINGThe Lanczos interpolation algorithm [10] uses a windowed form of sinc filter (an ideal low-pass filter) to perform interpolation on a 2-D grid. Sinc function of a variable can be mathematically obtained by dividing the sine function of the variable by itself [9]. Sinc function theoretically never goes to zero. Hence, a practical filter can be implemented by multiplying the sinc function with a window operator such as Hamming [24]-[25] and Hann [26] to obtain a filter with a finite size.The Lanczos filter can be obtained by multiplying the sinc function with the Lanczos window which is truncated to zero outside of the main lobe [27]. The size of the Lanczos window is defined by the order of theconvolution kernel.Figure 5. Lanczos image scaling algorithmThe number of neighbouring pixels considered varies as the order of the kernel. If the order is chosen to be 2, 16 pixels are considered while if the order is 3, 36 neighbouring pixels are utilized for interpolation. Forsufficient image quality, the order is chosen to be 3 in the implementation (Fig. 5).The Lanczos algorithm gives an output scaled image of the same quality as bicubic but at the cost of higher number of computations as 36 pixels is used for interpolating the value of each output pixel compared to 16 for bicubic. The Lanczos algorithm is comparatively more efficient for multiple scaling operations. E. M ODIFIED B ICUBIC I MAGE S CALINGAccording to the bicubic convolution kernel equation, massive calculations of four spots bicubic interpolation algorithm include large cubic and floating point multiplication operation. The bicubic interpolation algorithm discussed above can be slightly modified as shown below (Fig. 6). The co-efficients a0, a1, a2, a3, b0, b1, b2, and b3 are now a function of dx and dy (the difference between the interpolated co-ordinate and nearest integer source co-ordinate lower than it) instead of the interpolating pixels. This allows us to compute and store the values of the co-efficients for pre-determined values of dx and dy . This avoids the large number of cubic and floating point operations involved in bicubic interpolation.dy/6;*dy *dy + dy/6- = b3dy/2;*dy *dy - dy/2*dy +dy = b2dy/2;*dy *dy + dy/2*dy - dy/2 - 1 = b1dy/6;*dy *dy - /2dy *dy + /3dy - = b0dx/6;*dx *dx + dx/6- = a3dx/2;*dx *dx - dx/2*dx + dx = a2dx/2;*dx *dx + dx/2*dx - dx/2 - 1 = a1dx/6;*dx *dx - /2 dx * dx + /3 dx - = a0Where,C[3]*b3+C[2] *b2+C[1]*b1+C[0]*b0 = Cc d3*a3+ d2*a2+ d1*a1+d0*a0 =C[jj]Although the algorithm result has been influenced slightly, computation load is largely simplified. It mainly overcomes the disadvantage that hardware implementation of the algorithm is difficult due to many floating point computations.The search table modification to the bicubic interpolation algorithm is discussed in [28]. The distance, which the image regards as the unit length l, between two neighbouring pixels in the source image is divided equally into 16 sub-intervals. They are [0,1/16), [1/16,2/16), [2/16,3/16), [3/16,4/16), [4/16,5/16), [5/16,6/16), [6/16,7/16), [7/16,8/16), [8/16,9/16), [9/16,10/16), [10/16,11/16), [11/16,12/16), [12/16,13/16), [13/16,14/16), [14/16,15/16) and [15/16,1). The co-efficients for all 16 values of dx and dy can be computed beforehand and stored in memory. This reduces the computationally intensive process of determining the co-efficients in real-time. The value of dx and dy is compared to lie within one of the 16 sub-intervals and the values of coefficients a0, a1, a2, a2, b1,b2, b3, and b4 are chosen accordingly from pre-computed values.Figure 6. Modified bicubic image scaling algorithmIV. RESULT ANALYSISAll five algorithms are implemented in C/C++ language. OpenCV libraries are used for image read and write/display only. Dev-C++ (4.9.9.2) software installed on a standard Window XP machine is used for compilation and execution of C/C++ programs. Comparison of computational complexity of all five image scaling algorithms is shown in Table 1. Input test image of size 627x462 and corresponding scaled output images of size 150x150 produced by five implementations are shown in Fig. 7. Fig. 8 shows the input test image of size 609x594 and corresponding scaled output images of size 150x150 produced by five implementations.Non-adaptive algorithms always face a trade-off between the three image scaling artifacts – edge halo, blurring and aliasing. Nearest neighbour interpolation produces a high aliasing effect resulting in jagged edges. Bilinear interpolation reduces the aliasing effect but causes a moderate blurring of the edges. Bicubic interpolation produces a moderate aliasing, blurring and an edge halo effect. Lanczos interpolation delivers an image quality very similar to that of bicubic. Modified bicubic produces an output of slightly lesser quality as compared to bicubic as the co-efficients are approximated to reduce computational complexity. Computationally, nearest neighbour interpolation is the least intensive as it considers only one pixel forinterpolation. Bilinear uses 4 diagonal pixels for interpolation and therefore, requires more computation than the nearest neighbour method. Bicubic and Lanczos interpolation are computationally very intensive as they require 16 and 36 pixels respectively for interpolating an output pixel value. Lanczos interpolation also utilizes the sine function repeatedly which itself requires a large number of addition and multiplication operations according to Taylor series approximation. Modified bicubic interpolation reduces the number of computations significantly as the co-efficients are computed using search table.Table 1 : Computational Complexity ComparisonFigure 7. Input test image and corresponding output image for each algorithmFigure 8. Input test image and corresponding output image for each algorithmV.C ONCLUSIONImage scaling has become a fundamental processing task and plays an important role in video surveillance applications. Although there are a myriad of interpolation algorithms are available in literature, not all of them are suitable for implementing real-time image scaling. In this paper, we discussed the main non-adaptive image interpolation algorithms suitable for real-time applications. A comparative analysis of five image interpolation algorithms is presented based on the results of their software implementation. Of the five image interpolation algorithms evaluated, the modified bicubic algorithm offers the best trade-off between image quality and computational complexity for real-time image scaling in surveillance applications.A CKNOWLEDGMENTThe authors express their deep sense of gratitude to Dr. Chandra Shekhar, Director CSIR-CEERI for encouraging research and development activities. Authors would like to thanks Dr. AS Mandal and Raj Singh, Group Leader, IC Design Group, CSIR-CEERI, for their constructive suggestions throughout the year.R EFERENCES[1]J. Xiao, X. Zou, Z. Liu, X. Gu, A Novel AdaptiveInterpolation Algorithm For Image Resizing, International Journal of Innovative Computing,Information and Control, Vol. 3, n. 6(A), pp. 1335-1345, 2007.[2]Wolberg, G., Massalin, H., A Fast Algorithm forDigital Image Scaling, Proceedings of Computer Graphics International (Year of Publication: 1993).[3] F. Chin, A. Choi, Y. Luo, Optimal GeneratingKernels for Image Pyramids by Piecewise Fitting, IEEE Transactions on Pattern Analysis and Machine Intelligence, Vol. 14, n. 12, pp. 1190-1198, 1992.[4]P. Meer, E.S. Baugher, A. Rosenfeld, FrequencyDomain Analysis and Synthesis of Image Pyramid Generating Kernels, IEEE Transactions on Pattern Analysis and Machine Intelligence, Vol. PAMI-9, n.4, pp. 512-522, 1987.[5]P.P.Vaidyanathan, Multirate Systems and FilterBanks (Prentice Hall, 1993).[6]G. Wolberg, Digital Image Warping(IEEEComputer Society Press, 1992).[7]W.H. Press, B.P. Flannery, S.A. Teukolsky, W.T.Vetterling, Numerical Recipes: The Art of Scientific Computing (FORTRAN Version) (Cambridge University Press, 1989).[8] C. Boor, A Practical Guide to Splines (Springer-Verlag, 1978).[9]R.C. Gonzalez, R.E. Woods, Digital ImageProcessing (Prentice Hall, 2007).[10]K. Turkowski, Filters for common resampling tasks,In A.S. Glassner (Ed.), Graphic Gems, 4(San Diego: Academic Press, 1990, 147-170).[11]M. Unser, A. Aldroubi, M. Eden, Fast B-SplineTransforms for Continuous Image Representation and Interpolation, IEEE Transactions on Pattern Analysis and Machine Intelligence, Vol. 13, n. 3, pp.277-285, 1991.[12]Meijering, E.H.W., Niessen, W.J., Viergever, M.A.,The sinc-approximating kernels of classical polynomial interpolation, Proceedings of the International Conference on Image Processing (Page: 652-656 Year of Publication: 1999 ISBN:0-7803-5467-2).[13]Zhe, W., Jiefu, Z., Mengchu, Z., A FastAutoregression Based Image Interpolation Method, Proceedings of the IEEE International Conference on Networking, Sensing and Control (Page: 1400-1404 Year of Publication: 2008 ISBN:978-1-4244-1685-1).[14]Amanatiadis, A., Andreadis, I., Konstatinidis, K.,Fuzzy Area-Based Image Scaling, Proceedings of the IEEE Instrumentation and Measurement Technology Conference (Page: 1-6 Year of Publication: 2007 ISBN:1-4244-0588-2).[15]Mueller, N., Nguyen, T.K., Image interpolationusing classification and stitching, Proceedings of the IEEE International Conference on Image Processing (Page: 901-904 Year of Publication: 2008 ISBN:978-1-4244-1765-0).[16]Morse, B.S., Schwartzwald, D., Isophote-basedinterpolation, Proceedings of the IEEE International Conference on Image Processing (Page: 227-231 Year of Publication: 1998 ISBN:0-8186-8821-1). [17]Liang, F., Xie, K., An Image Interpolation Schemecombined with Artificial Neural Network, Proceedings of the Third International Conference on Natural Computation (Page: 99-102 Year of Publication: 2007 ISBN:978-0-7695-2875-5). [18]S.D. Ruikar, D.D. Doye, Image Denoising using TriNonlinear and Nearest Neighbour Interpolation with Wavelet Transform, International Journal of Information Technology and Computer Science, Vol.4, n. 9, pp. 36-44, 2012.[19]D. Su, P. Willis, Image Interpolation by Pixel LevelData-Dependent Triangulation,Computer Graphics Forum, Vol.23, n. 2, pp. 189-201, 2004.[20]Zhang, J., Kuo, C., Region-adaptive Texture-awareImage Resizing, Proceedings of the IEEE International Conference on Acoustics, Speech and Signal Processing (Page: 837-840 Year of Publication: 2012 ISBN:978-1-4673-0045-2). [21]Jiang, W., Xu, H., Chen, G., Zhao, W., Xu, W., AnImproved Edge-adaptive Image Scaling Algorithm, Proceedings of the IEEE Eighth InternationalConference on ASIC (Page: 895-897 Year of Publication: 2009 ISBN:978-1-4244-3868-6). [22]Lai, Y., Tzeng, C., Wu, H., Adaptive Image ScalingBased on Local Edge Directions, Proceedings of the International Conference on Intelligent and Advanced Systems (Page: 1-4 Year of Publication: 2010 ISBN:978-1-4244-6623-8).[23]Jenkins, W., Mather, B., Munson, D., Jr., NearestNeighbor And Generalized Inverse Distance Interpolation For Fourier Domain Image Reconstruction, Proceedings of the IEEE International Conference on Acoustics, Speech and Signal Processing (Page: 1069-1072 Year of Publication: 1985).[24]W. Ye, A. Entezari, A Geometric Construction ofMultivariate Sinc Functions, IEEE Transactions on Image Processing, Vol.21, n. 6, pp. 2969-2979, 2012.[25]Xiao, L., Dong, X., Soong, A.C.K., EffectiveInterpolator Design for Pilot Symbol Assisted Modulation Systems, Proceedings of the IEEE Global Telecommunications Conference (Page: 3671-3675 Year of Publication: 2004 ISBN:0-7803-8794-5).[26]Wenbo, T., Jianming, Y., Xiaojin, M., Ji, L., Powersystem harmonic detection based on Bartlett–Hann Windowed FFT interpolation, Proceedings of the Asia-Pacific Power and Energy Engineering Conference (Page: 1-3 Year of Publication: 2012 ISBN:978-1-4577-0545-8).[27]Ye, Z., Suri, J., Sun, Y., Janer, R., Four ImageInterpolation Techniques for Ultrasound Breast Phantom Data Acquired Using Fischer's Full Field Digital Mammography and Ultrasound System (FFDMUS): A Comparative Approach, Proceedings of the IEEE International Conference on Image Processing (Page: 1238-1241 Year of Publication: 2005 ISBN:0-7803-9134-9).[28]Zhang, Y., Li, Y., Zhen, J., The HardwareRealization of Bicubic Interpolation Enlargement Algorithm Based on FPGA, Proceedings of the Third International Symposium on Information Processing (Page: 277-281 Year of Publication: 2010 ISBN:978-1-4244-8627-4).Chetan Suresh is pursuing hisundergraduate study in BITS-Pilani,Rajasthan, India. He is a final yearstudent of Electrical and ElectronicsEngineering. Currently, he isworking as a student intern inCambridge Silicon Radio, Bangalore. His research interests are FPGA Prototyping and Computer Architecture.Sanjay Singh is workingas Scientist in CSIR-CentralElectronics Engineering ResearchInstitute, Pilani, Rajasthan, India. Heis Member of IEEE - USA, IACSIT- Singapore, and IAENG - HongKong. Currently, he is involved in various projects sponsored by Indian Government on Computer Vision and Smart Cameras. His research interests are VLSI architectures for image & video processing algorithms, FPGA Prototyping, and Computer Vision. Prior to joining this research lab, he received his Master in Technology, Master in Electronics, and Bachelor in Science in 2007, 2005, and 2003 respectively from Kurukshetra University, Kurukshetra, Haryana, India. He earned Gold Medal (First Position in University) during his Master in Technology and Master in Electronics. He topped college during his Bachelor in Science. He received more than 20 Merit Certificates and Scholarships during his academic career.Ravi Saini is working as Scientist inCSIR-Central ElectronicsEngineering Research Institute,Pilani, Rajasthan, India. He isMember of IEEE –USA. Hisresearch interests include VLSIArchitectures, ASIC and ASIPDesign, HDLs, and FPGA Prototyping. He received his Master in Technology in 2002 from Punjab University, India and Master in Electronics in 2000 from DAVV, Indore, India.Anil Kumar Saini is workingas Scientist in CSIR-CentralElectronics Engineering ResearchInstitute, Pilani, Rajasthan, India.He is Member of IEEE – USA andIACSIT –Singapore. His researchinterests include Analog andMixed Signal Design, Embedded System Design, and CMOS RF IC design. Prior to joining this research lab, he worked in Cadence, India. He received his Master in Technology and Master in Science in 2003 and 2000 respectively from IIT Roorkee, India.。