摘要
针对当前基于CUDA的中值滤波并行加速算法存在的编程复杂,图像数据提取和显示环节实现繁琐等问题提出了利用MATLAB和OpenACC结合的并行算法。该算法采用MATLAB实现图像的提取并转换成数组文件,之后利用OpenACC实现串行代码到并行代码的转换并处理MATLAB转换的数组文件,最后通过MATLAB将滤波后的数据显示成图像。通过仿真实验进行中值滤波算法的加速实验,结果表明:提出的算法在大量减少代码转换工作量的情况下加速效果较串行程序提升明显且与CUDA加速效果相当。
In this paper,a parallel algorithm combining MATLAB and OpenACC is proposed for the complex programming problems of current CUDA-based median filtering parallel acceleration algorithm and the cumbersome implementation of image data extraction and display. The algorithm uses MATLAB to extract the image and converts it into an array file. Then it uses the OpenACC language to convert the serial code to the parallel code and processes the array file converted by MATLAB. Finally,the filtered data is displayed as an image through MATLAB. The acceleration experiment of the median filtering algorithm is carried out by simulation experiments. The experimental results show that the proposed algorithm accelerates the algorithm faster than the serial program in the case of greatly reducing the amount of code conversion workload. And it is equivalent to the effect of CUDA acceleration.
引文
[1]丁毅乐.基于CUDA架构的遥感图像滤波算法并行处理[D].郑州:解放军信息工程大学,2017.
[2]吕亚飞,贾堃阳.基于CUDA的快速中值滤波算法[J].现代计算机:专业版,2011,2011(13):3-6.
[3]雷芸,LEIYun.基于中值预滤波的非局部平均去噪算法[J].微电子学与计算机,2015(5):138-142.
[4]蔡明晧,范秋华.一种便于实时传输的中值滤波算法[J].制造业自动化,2018(7).
[5]SHARMAS,SUBRAMANYAMAV,JAINM,et al.Anti-forensic technique for median filtering using L1-L2 TV model[C]//IEEE International Workshop on Information Forensics and Security. IEEE,2017:1-6.
[6]ZHANG C R,QIU Y E,LEI T,et al.A fast vector median filtering algorithm based on minimal reference distance[J]. Electronic Design Engineering,2018.
[7]GREEN O.Efficient Scalable Median Filtering Using Histogram-Based Operations.[J]. IEEE Transactions on Image Processing A Publication of the IEEE Signal Processing Society,2018,27(5):2217.
[8]ZHANG S,LI X,ZHANG C.Modified Adaptive Median Filtering[C]//International Conference on Intelligent Transportation,Big Data&Smart City. IEEE,2018:262-265.