在GPU通用计算架构下,首次提出了CUDA架构下的液晶自适应光学波面数值解析方法。针对高分辨率液晶自适应光学系统,介绍了液晶自适应光学的波面数值解析算法,论述了CUDA的通用架构;然后,建立了CUDA实现波面数值解析的编程模型,在此模型中引入了并行线程的有效利用,全局存储器的高效访问和数据直接回写3种优化方案;最后,给出了GPU与CPU的实验对比结果。结果表明:CUDA计算分辨率为512×512,对35项Zernike多项式的波面数值解析需时不到1ms,计算速度是传统CPU波面数值解析的几十倍。提出的方法减小了系统延时,提高了校正速度,建立波面数值解析CUDA编程模型采用的优化手段可为其它数学计算模型提供参考。
A Zernike modal wavefront calculation method based on Computer Unified Device Architecture(CUDA) was presented for liquid crystal adaptive optical systems under the GPU general architecture.The wavefront calculation method was introduced and the CUDA characteristics were given.Then,a programming model for wavefront calculation by CUDA was established,in which it involved three kinds of optimized schemes including maximum threads,higher memory and transfer bandwidth.The method based on CUDA was tested and compared with the traditional method using CPU,and result shows that the consumed time by proposed method is less than 1 ms for a Zernike polynomial with 35 wavefromt values in resolution of 512×512,which means that GPU provides a computational power tens times greater than that of usual CPU-FPU combination.The method has reduced the system delay and improved correction speed and its optimized ideas for programming model can provide a reference for other computer models.