摘 要

卷积神经网络是近年来人工智能领域取得重大突破的一种重要手段,给出了图像识别、语音识别和自然语言处理领域中关键问题的优化解决方案,尤其适合处理图像方面的任务,如人脸识别和手写体识别。手写数字识别是用卷积神经网络解决的经典问题,采用一般方法训练出来的神经网络达到了97%的识别率,几乎与人类的识别精度一致,但在执行速度上没有人类识别得快。在实际商业应用中不可避免地会遇到数据量过大的问题,如在手写数字识别中有60000条规格为28*28单位像素的训练样本需要训练,这样会导致执行速度较慢,CPU在处理这样包含大量高精度浮点数的任务时,其消耗的时间是不可接受的,在训练期要花费数小时的时间。

针对上述问题,该文将构建基于CUDA架构的编程环境,采用CUDA/C++编程实现卷积神经网络算法,将卷积神经网络算法应用于手写数字识别问题中,在选择合适的网络模型和相关参数的情况下,利用GPU的高度并发性能,提高卷积神经网络训练数据的速度。通过对GPU实现和CPU实现进行对比实验,验证对卷积神经网络算法进行CUDA并行化训练和识别是可行有效的,实验表明在普通PC机上采用GPU实现的卷积神经网络算法比CPU实现的卷积神经网络算法虽然在准确率上仅提升了0.29%,但在速度上加快了15%。

关键词:CUDA,卷积神经网络,深度学习,并行计算

ABSTRACT

Convolutional neural network is a major breakthrough in the field of artificial intelligence in recent years, an important means of image recognition given to optimize speech recognition and natural language processing solutions, especially for process images tasks, such as human face recognition and handwriting recognition. Handwritten numeral recognition is a classic problem with the convolutional neural network to solve, using the general method of trained neural network reaches 97% recognition rate, with almost the same human recognition accuracy, but the speed of execution without human recognition quickly. In practical commercial applications will inevitably encounter the problem of data overload, as there are 60,000 training sample size is 28 * 28 pixel units need to be trained in digital handwriting recognition, this will result in slower performance, CPU in when processing tasks such contains a lot of high-precision floating-point number, the elapsed time is unacceptable, in the training period to spend a few hours.

To solve these problems, this paper will build a CUDA architecture-based programming environment using CUDA / C ++ programming to implement the convolution neural network algorithm. The convolution neural network algorithm is applied to handwritten numeral recognition problem. After selecting an appropriate network model and related parameters, the use of highly concurrent GPU performance,convolution neural network training to improve the speed of data. Then use the model to achieve the GPU and CPU to complete some comparative tests to verify the fact that using the CUDA to parallel implementing convolution neural network algorithm for training and recognition is feasible and effective,experiments show that on the common PC the neural network algorithm convolution convolution neural network algorithm to achieve GPU than CPU implementations on the speed by 15%, on the accuracy improved 0.29%.

Key words:CUDA, CNN, Deep Learning, Parallel Computing

18423381-d4bfa5e10c8484b7.png

源码下载地址:https://www.write-bug.com/article/1773.html

Logo

CSDN联合极客时间,共同打造面向开发者的精品内容学习社区,助力成长!

更多推荐