arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2104.08002cs.LGcs.AIcs.DC
收藏

用于深度学习的高效和通用的1D扩张卷积层

Efficient and Generic 1D Dilated Convolution Layer for Deep Learning

Intel Labs(英特尔实验室);Intel Corporation(英特尔公司)

Narendra Chaudhary, Sanchit Misra, Dhiraj Kalamkar, Alexander Heinecke, Evangelos Georganas, Barukh Ziv, Menachem Adelman, Bharat Kaul

摘要:

卷积神经网络(CNN)已经在涉及二维(2D)数据的任务中发现了许多应用,诸如图像分类和图像处理。因此,2D卷积层在CPU和GPU上进行了大量优化。然而,在许多应用中-例如基因组学和语音识别,数据可以是一维(1D)的。这些应用可以从优化的1D卷积层中受益。在这项工作中,我们介绍了一个通用的1D卷积层,涵盖了广泛的参数,我们的有效实现。它针对x86 CPU架构进行了优化,特别是包含Intel AVX-512和AVX-512 BFloat 16指令的架构。我们使用LIBXSMM库的批量减少通用矩阵乘法(BRGEMM)内核来实现FP 32和BFloat 16精度。我们证明了我们的实施可以在英特尔至强Cascade Lake和Cooper Lake CPU上实现高达80%的效率。此外,我们展示了我们的BRGEMM为基础的方法的泛化能力,通过在一系列参数实现高效率。对于不同的输入张量宽度、滤波器宽度、通道数、滤波器和膨胀参数,我们始终实现比使用英特尔oneDNN库后端的1D卷积层更高的效率。最后,我们通过将其用于具有真实基因组数据集的端到端神经网络训练来展示我们优化的1D卷积层的性能,并在Cascade Lake CPU上实现了高达6.86倍的基于oneDNN库的加速比。我们还演示了16个插槽的Cascade/Cooper Lake CPU的扩展,并使用类似的功率包络在8个V100 GPU上实现了显著的加速。在端到端训练中,我们在Cascade Lake上使用FP 32获得了1.41倍的加速比,在Cooper Lake上使用FP 32获得了1.57倍的加速比,在Cooper Lake上使用BFloat 16获得了2.27倍的加速比。

英文摘要:

Convolutional neural networks (CNNs) have found many applications in tasks involving two-dimensional (2D) data, such as image classification and image processing. Therefore, 2D convolution layers have been heavily optimized on CPUs and GPUs. However, in many applications - for example genomics and speech recognition, the data can be one-dimensional (1D). Such applications can benefit from optimized 1D convolution layers. In this work, we introduce our efficient implementation of a generic 1D convolution layer covering a wide range of parameters. It is optimized for x86 CPU architectures, in particular, for architectures containing Intel AVX-512 and AVX-512 BFloat16 instructions. We use the LIBXSMM library's batch-reduce General Matrix Multiplication (BRGEMM) kernel for FP32 and BFloat16 precision. We demonstrate that our implementation can achieve up to 80% efficiency on Intel Xeon Cascade Lake and Cooper Lake CPUs. Additionally, we show the generalization capability of our BRGEMM based approach by achieving high efficiency across a range of parameters. We consistently achieve higher efficiency than the 1D convolution layer with Intel oneDNN library backend for varying input tensor widths, filter widths, number of channels, filters, and dilation parameters. Finally, we demonstrate the performance of our optimized 1D convolution layer by utilizing it in the end-to-end neural network training with real genomics datasets and achieve up to 6.86x speedup over the oneDNN library-based implementation on Cascade Lake CPUs. We also demonstrate the scaling with 16 sockets of Cascade/Cooper Lake CPUs and achieve significant speedup over eight V100 GPUs using a similar power envelop. In the end-to-end training, we get a speedup of 1.41x on Cascade Lake with FP32, 1.57x on Cooper Lake with FP32, and 2.27x on Cooper Lake with BFloat16 over eight V100 GPUs with FP32.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑