Neural network acceleration method and device, accelerator and storage medium

The invention provides a neural network acceleration method and device, an accelerator and a storage medium. The method comprises the following steps: respectively converting an input picture and a preset convolution kernel into a first matrix and a second matrix; inputting the first matrix and the...

Ausführliche Beschreibung

Gespeichert in:
Bibliographische Detailangaben
Hauptverfasser: SONG QINGZENG, XUE YONGJIANG
Format: Patent
Sprache:chi ; eng
Schlagworte:
Online-Zugang:Volltext bestellen
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
Beschreibung
Zusammenfassung:The invention provides a neural network acceleration method and device, an accelerator and a storage medium. The method comprises the following steps: respectively converting an input picture and a preset convolution kernel into a first matrix and a second matrix; inputting the first matrix and the second matrix into a systolic array to realize convolution operation to obtain a third matrix; normalizing the third matrix through a first formula; the normalized third matrix is used for performing self-attention operation of the neural network. According to the neural network acceleration method and device, the accelerator and the storage medium provided by the invention, the operation speed of the Vision Transform neural network can be improved. 本公开提供了一种神经网络加速方法及装置、加速器、存储介质,该方法包括:将输入图片和预设的卷积核分别转换为第一矩阵和第二矩阵;将所述第一矩阵和所述第二矩阵输入至脉动阵列以实现卷积运算,得到第三矩阵;通过第一公式对第三矩阵进行归一化;所述归一化后的第三矩阵用于进行神经网络的自注意力运算。本公开提供的神经网络加速方法及装置、加速器、存储介质可以提高Vision Transformer神经网络的运算速度。