数据与计算发展前沿 ›› 2022, Vol. 4 ›› Issue (2): 29-38.

doi: 10.11871/jfdc.issn.2096-742X.2022.02.003

• 专刊:先进智能计算平台及应用 • 上一篇    下一篇

MXNet框架中基于OpenCL核函数的多维线性数据处理

甘润东(),沈舒尹*(),张宇哲()   

  1. 南开大学,软件学院,天津 300450
  • 收稿日期:2022-02-08 出版日期:2022-04-20 发布日期:2022-04-30
  • 通讯作者: 沈舒尹
  • 作者简介:甘润东,南开大学,软件学院,硕士研究生,主要研究方向为基于深度学习的场景识别。
    本文中负责解决方案以及实验和结论总结的编写。
    GAN Rundong is a master student at the College of Software, Nankai University. His main research direction is scene recognition based on deep learning.
    In this article, he is responsible for the writing of the solution and the conclusion summary.
    E-mail: raineast666@163.com|沈舒尹,南开大学,软件学院,硕士, 实验师,研究方向为算法设计、知识图谱构建、教育信息化技术标准。
    本文中负责并行计算框架中多维数据操作部分的编写以及论文的总体统稿。
    SHEN Shuyin, Master, is a laboratory technician at the College of Software of Nankai University. Her research interests in-clude algorithm design, knowledge graph construction and edu-cation, and information technology standard.
    In this paper, she is responsible for the writing of the mult-idimensional data manipulation part of the parallel computing framework and the overall draft of the thesis.
    E-mail: shenshuyin@nankai.edu.cn|张宇哲,南开大学,软件学院,硕士研究生,主要研究方向为人工智能。
    本文中负责并行计算平台运行机制的编写。
    ZHANG Yuzhe is a master student at the School of Software, Nankai Univ-ersity. His main research direction is artificial intelligence.
    In this paper, he is responsible for the writing of the operating mechanism of the parallel computing platform.
    E-mail: zyzcs@mail.nankai.edu.cn
  • 基金资助:
    国家重点研发计划(2021YFB0300104)

Multidimensional Linear Data Processing Based on OpenCL Kernel Function in MXNet Framework

GAN Rundong(),SHEN Shuyin*(),ZHANG Yuzhe()   

  1. College of Software, Nankai University, Tianjin 300450, China
  • Received:2022-02-08 Online:2022-04-20 Published:2022-04-30
  • Contact: SHEN Shuyin

摘要:

【目的】在深度学习框架中,为了实现大规模深度学习计算,异构的OpenCL计算模型通过充分利用不同厂商生产的不同类型硬件设备和计算资源成为提升学习效率的重要途径。因此将深度学习框架例如MXNet等迁移至OpenCL计算模型上以提高其对大规模深度学习的适配性。在对MXNet深度学习框架的迁移过程中,深度学习计算中较为普遍的多维线性数据处理相关操作的迁移则是本文需要讨论的主要问题。【方法】通过系统地比较CUDA计算模型和OpenCL计算模型的运行机制,将已兼容CUDA计算模型的MXNet深度学习框架中对多维线性数据处理的逻辑基于OpenCL计算模型进行适配性重构。【结果】通过基于OpenCL计算模型进行适配性重构的MXNet深度学习计算框架中的有关多维线性数据处理的计算操作能够通过已有的框架测试。【结论】基于OpenCL计算模型进行适配性重构方案能够很好地解决MXNet深度学习框架迁移至OpenCL计算模型时较为普遍的多维线性数据处理相关操作的迁移问题。

关键词: OpenCL kernel程序, MXNet, 多维线性数据计算

Abstract:

[Objective] In the deep learning framework, in order to realize large-scale deep learning computing, the heterogeneous OpenCL computing model has become important to improve learning efficiency by making full use of different types of hardware devices and computing resources produced by different manufacturers. Therefore, deep learning frameworks such as MXNet are migrated to the OpenCL computing model to improve their adaptability to large-scale deep learning. In the process of migrating the MXNet deep learning framework, the migration of operations related to multi-dimensional linear data processing, which is common in deep learning computing, is the main issue discussed in this paper. [Methods] By systematically comparing the operating mechanisms of the CUDA computing model and the OpenCL computing model, the logic of multi-dimensional linear data processing in the MXNet deep learning framework compatible with the CUDA computing model is reconstructed based on the OpenCL computing model. [Results] The computing operations related to multi-dimensional linear data processing in the MXNet deep learning computing framework based on the OpenCL computing model for adaptive reconstruction can pass the existing framework tests. [Conclusions] The adaptive reconstruction scheme based on the OpenCL computing model can well solve the common migration problem of multi-dimensional linear data processing related operations when the MXNet deep learning framework is migrated to the OpenCL computing model.

Key words: OpenCL kernel program, MXNet, multidimensional linear data calculation