Skip to content

  • 体验新版
    • 正在加载...
  • 登录
  • PaddlePaddle
  • Paddle
  • 合并请求
  • !14441

P
Paddle
  • 项目概览

PaddlePaddle / Paddle
大约 2 年 前同步成功

通知 2325
Star 20933
Fork 5424
  • 代码
    • 文件
    • 提交
    • 分支
    • Tags
    • 贡献者
    • 分支图
    • Diff
  • Issue 1423
    • 列表
    • 看板
    • 标记
    • 里程碑
  • 合并请求 543
  • Wiki 0
    • Wiki
  • 分析
    • 仓库
    • DevOps
  • 项目成员
  • Pages
P
Paddle
  • 项目概览
    • 项目概览
    • 详情
    • 发布
  • 仓库
    • 仓库
    • 文件
    • 提交
    • 分支
    • 标签
    • 贡献者
    • 分支图
    • 比较
  • Issue 1,423
    • Issue 1,423
    • 列表
    • 看板
    • 标记
    • 里程碑
  • 合并请求 543
    • 合并请求 543
  • Pages
  • 分析
    • 分析
    • 仓库分析
    • DevOps
  • Wiki 0
    • Wiki
  • 成员
    • 成员
  • 收起侧边栏
  • 动态
  • 分支图
  • 创建新Issue
  • 提交
  • Issue看板

Implementing ngraph engine !14441

  • Report abuse
!14441 已合并 11月 16, 2018 由 saxon_zh@saxon_zh 创建
#<User:0x00007f0ef2db9798>
  • 概览 27
  • 提交 8
  • 变更 11

Created by: baojun-nervana

This PR includes the implementation of ngraph engine. Each function's role in the NgraphOperator class:

  1. GetNgInputShape : this uses the infershape to get the output shape as ngraph needs to know this info to define tensor;
  2. BuildNgIO : this is to get the input and output var list;
  3. BuildNgNode: this function call ngraph bridge function BuildNgGraph to translate ops and build the computation graph.
  4. BuildNgFunction : this is to build the function for ngraph as ngraph use a function call to execute the computation.
  5. GetNgFunction : ngraph function can be cached, so this api will check if a function is already available or otherwise it will call BuildNgFunction to build a new ngraph function; GetCacheKey is to generate the key to map the function;
  6. Run : will set the input and output tensor and call the function to execute. Input and output tensors were shared with paddle to save IO cost;

Note:

  1. The api VarIsTensor and class RuntimeInferShapeContex were promoted from operator.cc and operator.h, so it is accessible for ngraph_operator;
  2. I added ngraph object dependency in cmake to ensure ngraph is available before build ngraph_bridge and ngraph_operator (can be an issue to build in large system and the orders can be guaranteed this way);
  3. I added Relu and Tanh as examples in the bridge to show how the bridge works. More ops can be seen from https://github.com/PaddlePaddle/Paddle/pull/13389 (I have all resnet50 ops there, so you can run resnet to check performance).

CC: @luotao1 @panyx0718 @jianhang-liu

指派人
分配到
审核者
Request review from
无
里程碑
无
分配里程碑
工时统计
标识: paddlepaddle/Paddle!14441
Source branch: github/fork/baojun-nervana/intel/ngraph_op
渝ICP备2023009037号

京公网安备11010502055752号

网络110报警服务 Powered by GitLab CE v13.7
开源知识
Git 入门 Pro Git 电子书 在线学 Git
Markdown 基础入门 IT 技术知识开源图谱
帮助
使用手册 反馈建议 博客
《GitCode 隐私声明》 《GitCode 服务条款》 关于GitCode
Powered by GitLab CE v13.7