登录

  • 登录
  • 忘记密码?点击找回

注册

  • 获取手机验证码 60
  • 注册

找回密码

  • 获取手机验证码60
  • 找回
毕业论文网 > 毕业论文 > 电子信息类 > 通信工程 > 正文

卷积神经网络前向反向算法研究及加速器设计毕业论文

 2021-11-06 11:11  

摘 要

在当今社会,随着互联网行业的快速发展和相应技术的不断进步,人们对智能化的产品的需求越来越高,人们需要将许多重复甚至比较复杂的工作交给机器去做,以此节约工作时间,从而提高完成工作的效率。从马路上的监控相机,到工厂中的智能摄像头,人们开始需要将大量的图像处理工作交给计算机处理,以提高工作的效率,因此计算机视觉为人们的生活提供了很多的便利。而在计算机视觉中,最重要的就是卷积神经网络(Convolutional Neural Network, CNN)了,它仿造了人类的复杂器官大脑中的神经元的工作原理,并且又运用了大量的卷积运算来实现识别功能,因此被称为卷积神经网络,它的效果稳定并且没有额外的特征工程要求。在当前的研究中,已经有许多领域广泛应用了卷积神经网络,包括图像处理和声音信号处理,并且深度学习的方法已经超越了人类的认知和分类的水平。卷积神经网络之所以能够得到广泛的应用并优于其他的神经网络,是因为它所需要的参数要少于其他的神经网络。由于卷积神经网络具有巨大的计算量,近年来有许多对于其加速方法的研究。卷积神经网络一般是使用软件方法实现的,但是随着人们的需求增加,基于软件的实现方法不能实现其并行性,因此有许多研究转向使用利用硬件加速卷积神经网络。而其中由于可编程逻辑门阵列(Field-Programmable Gate Array, FPGA)拥有高灵活性、高能效、高性能等优点被广泛地应用于CNN的加速。

本设计首先分析了卷积神经网络的前向与反向算法的基本原理,然后使用Python编程实现了一个完整的模型,验证了在其前向与反向传播中主要计算单元中参数的更新计算过程,包括误差传播过程和权重梯度计算过程。然后,介绍并分析了卷积神经网络中的一个经典模型LeNet-5,使用TensorFlow逐层构建了这个模型,实现了手写数字识别系统,并研究了卷积层参数对其训练速度的影响。最后,总结了几种卷积神经网络的软件和硬件加速方法。本次设计使用的是MNIST数据集进行训练,训练结果精度最高达到99.01%。

关键词:卷积神经网络;CNN加速;前向传播;反向传播;TensorFlow

Abstract

In today's society, with the rapid development of the Internet industry and the continuous advancement of corresponding technologies, people's demand for intelligent products is getting higher and higher. People need to hand over many repetitive or even more complicated tasks to machines to save working time, thereby improving the efficiency of completing the work. From the cameras on the road to smart cameras in factories, people begin to need to hand over a large amount of image processing work to computers to improve the efficiency of their work, so computer vision provides a lot of convenience for people's lives. In computer vision, the main thing is the convolutional neural networks(CNN). Convolutional neural networks imitate the working principles of neurons in the brains of human, and use a large number of convolution operations to achieve recognition functions, hence they are called convolutional neural networks. It is stable and has no additional feature engineering requirements. In the current research, convolutional neural networks have been widely used in many fields, including image processing and sound signal processing, and deep learning methods have achieved levels beyond human cognition and classification. The reason why convolutional neural networks can be widely used and superior to other neural networks is because it requires fewer parameters than other neural networks. Because convolutional neural networks have a huge amount of computation, there have been many studies on their acceleration methods in recent years. Convolutional neural networks are generally implemented using software methods, but as people's needs increase, software-based implementation methods cannot achieve parallelism, so many studies have turned to using hardware to accelerate convolutional neural networks. Due to the advantages of Field-Programmable Gate Array (FPGA) with high flexibility, high energy efficiency, high performance, etc., it is widely used in the acceleration of CNN.

This design first analyzes the basic principles of the forward propagation and back propagation algorithms of convolutional neural networks, and then uses Python programming to implement a complete model, verifying its process of calculating and updating the parameters in the main computing units in propagation, including the error propagation process and the weight gradient calculation process. Then, a classic model LeNet-5 is introduced and analyzed. This model is constructed using the functions in TensorFlow, and a handwritten digit recognition system is implemented, and the effect of convolutional layer parameters on its training speed is studied. Finally, several software and hardware acceleration methods for convolutional neural networks are summarized. This design uses the MNIST data set, and the accuracy of the training results is up to 99.01%.

Keywords: Convolutional Neural Network; CNN Accelerator; Forward Propagation; Back Propagation; TensorFlow

目录

第一章 绪论 1

1.1课题研究的背景、目的与意义 1

1.2国内外研究现状 2

1.3课题研究内容 2

1.3.1课题研究的主要内容 2

1.3.2采用的主要技术方案 3

1.4预期目标 3

第二章 设计方案原理论证 4

2.1 卷积神经网络简介 4

2.1.1基本概念 4

2.1.2 数据输入层 4

2.1.3 卷积层 4

2.1.4 激励层 5

2.1.5 池化层 7

2.1.6 全连接层 8

2.2 LeNet-5网络简介 8

2.3 前向传播算法 9

2.3.1 输入层的前向传播 9

2.3.2 卷积层的前向传播 9

2.3.3 池化层的前向传播 10

2.3.4 全连接层的前向传播 10

2.4 卷积神经网络的反向传播 10

2.5 TensorFlow简介 11

2.6 FPGA简介 11

2.7 高层次综合 11

2.8 卷积神经网络加速 12

2.8.1卷积核分解 12

2.8.2 Bottleneck Layers 12

2.8.3 卷积核数合并 12

2.8.4 FPGA加速 13

第三章 课题实验过程论述 14

3.1 卷积神经网络前向与反向算法实现方案 14

3.1.1 卷积层实现 14

3.1.2 卷积层的前向传播 15

3.1.3卷积层的反向传播 15

3.1.4 池化层实现与前向及反向传播 15

3.2 LeNet-5实现方案 16

3.2.1 数据预处理 16

3.2.2 模型构建 16

3.2.3 模型训练 16

3.3 FPGA加速器实现 17

第四章 实验结果 18

4.1 前向与反向算法结果验证 18

4.1.1 卷积层验证 18

4.1.2 池化层验证 19

4.2 LeNet-5模型训练结果 20

4.3 卷积层参数影响 22

第五章 结论 24

5.1 课题工作总结 24

5.2 展望 24

参考文献 25

致 谢 27

第一章 绪论

1.1课题研究的背景、目的与意义

卷积神经网络的设计遵循生物体内的视觉处理,它模仿了视觉皮层细胞中局部过滤的作用,以挖掘自然维空间中的局部相关性,它是一个专门设计的多层感知器,可以识别二维形状。因此,保留在波形点中的维度信息可以被有效地利用。由于其具有自适应特征提取的特性,因此被用于图像识别和语音信号的情感识别。对于它的研究可以追溯到福岛邦彦在1980年提出的“neocognitron”。neocognitron要求位于多个网络位置的单元具有相同的权重,它在CNN中引入了两种基本类型的层:卷积层和下采样层。卷积层包含的单元能够覆盖前一层的一部分,这种权重向量(自适应参数集)通常称为过滤器。同样,下采样层包含的单元能够覆盖前一层的一部分,这样的单元通常计算其中的平均值。这种下采样有助于在视觉场景中正确分类对象,即使对象已移动也是如此。

几十年来,人们已经提出了几种有监督和无监督的学习算法来训练neocognitron的权重,但是现在,CNN架构通常通过反向传播进行训练。1988年,人们将neocognitron用于分析时变信号。

您需要先支付 80元 才能查看全部内容!立即支付

企业微信

Copyright © 2010-2022 毕业论文网 站点地图