已合并
add bidirection_lstm,bidirection_lstmv2 example #1909
LSYlsy0214创建于 2月13日
add bidirection_lstm,bidirection_lstmv2 example #1909
已合并
LSYlsy0214创建于 2月13日
LSYlsy0214
2月13日

描述

bidirection_lstm,bidirection_lstmv2缺少example示例

关联的Issue

https://gitcode.com/cann/ops-nn/issues/1060

测试

文档更新

类型标签

likedislike
Pull Request已成功合入, 合并人@CANN-robot
(感谢 LSYlsy0214 的贡献)
LLSYlsy0214
2月13日 创建了 pull request,commit 79197cc3
CANN-robot
CANN-robot成员
2月13日 评论:

Thanks for your pull-request.
The full list of commands accepted by me can be found at here
You can get sig-info at here


PR Approval Progress

Congratulations! All modules have met the lgtm and approve requirements.

Module Approval Details

module lgtm status approve status
rnn crystalhu, zhangyuxiang0119 (2/2) crystalhu (1/1)

💡 Tip:

  • Committer can comment /approve or /lgtm
  • Commenting /approve implies both code review (lgtm) and intent to merge (approve)
likedislike
CANN-robotCANN-robot成员
2月13日 将crystalhu,fanqirui,zhou-qilong,chenqi317,liubo75,tangweiwei2,zhangyuxiang0119,wangyongguang,zhang-wu设为评审人
CANN-robotCANN-robot成员
2月13日 添加了label:cann-cla/yes
CANN-robotCANN-robot成员
2月13日 将crystalhu,zhou-qilong,chenqi317,liubo75,tangweiwei2,zhangyuxiang0119,wangyongguang,zhang-wu设为审查人
CANN-robot
CANN-robot成员
2月13日 评论:

CLA Signature Pass

LSYlsy0214, thanks for your pull request. All authors of the commits have signed the CLA. 👍

likedislike
CANN-robot
CANN-robot成员
2月13日 评论:

🔵 source code change are detected, tasks labels is removed in this pull request!

likedislike
CANN-robot
CANN-robot成员
2月13日 评论:

问题/功能描述

本次PR新增了两个独立的C++示例程序,分别用于测试华为CANN算子库中的aclnnBidirectionLSTMaclnnBidirectionLSTMV2算子。这两个程序旨在为开发者提供标准、完整的API调用参考,展示从设备初始化、张量创建、工作空间计算、算子执行到资源释放的全流程,以验证算子的正确使用方式。

修改方案描述

方案新增了两个完整的C++测试文件。每个文件均实现了对特定双向LSTM算子的调用,核心内容包括:1)封装了ACL设备、流和内存的初始化与释放函数;2)提供了通用的张量创建工具函数,支持从主机数据创建设备侧ACL张量;3)严格按照“两段式”接口规范(先获取工作空间大小,再执行算子)调用目标算子;4)定义了测试所需的网络参数(如时间步、批次大小、隐藏层大小),并创建了所有必需的输入、输出及状态张量;5)实现了结果打印和所有申请资源(设备内存、张量对象)的清理逻辑,确保无内存泄漏。

likedislike
LSYlsy0214
2月13日 评论:

compile

likedislike
CANN-robotCANN-robot成员
2月13日 添加了label:ci-pipeline-running
CANN-robot
CANN-robot成员
2月13日 评论:

流水线任务触发成功 [流水线指导]
任务链接 [018ca21e74b345f5abe63fc126e28930]

任务名称状态日志下载链接
codecheck ✅ SUCCESS >>>>>
anti_virus ✅ SUCCESS >>>>>
Check_Pr ✅ SUCCESS >>>>>
Compile_Ascend_X86 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_mobile_station ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_single ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_experimental ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_X86_950 ✅ SUCCESS >>>>> >>>>>
Compile_Ascend_ARM_950 ✅ SUCCESS >>>>> >>>>>
API_Check ✅ SUCCESS >>>>>
Pre_Compile ✅ SUCCESS
pre_comment ✅ SUCCESS >>>>>
UT_Test_ophost ✅ SUCCESS
UT_Test_opapi ✅ SUCCESS
UT_Test_kernel ✅ SUCCESS
UT_Test_opgraph ✅ SUCCESS
Smoke_A900_npupool ✅ SUCCESS >>>>>

[2026-02-13 10:51:41]    CI执行结束

likedislike
CANN-robotCANN-robot成员
2月13日 添加了label:api-check-pass
CANN-robotCANN-robot成员
2月13日 删除了label:ci-pipeline-running
CANN-robotCANN-robot成员
2月13日 添加了label:ci-pipeline-passed
LLSYlsy0214
2月13日 修改标题为 “add bidirection_lstm,bidirection_lstmv2 example”,原标题为“add example”
LLSYlsy0214
2月13日 修改了pull request 的描述
张喻翔
张喻翔
2月13日 评论:

/lgtm

likedislike
胡碧霞成员
2月13日 评论:

/approve

likedislike
CANN-robotCANN-robot成员
2月13日 添加了label:lgtmapproved
CANN-robot
CANN-robot成员
2月13日 评论:

Review Guide

This pull-request passes review.
Committers who wrote a comment of /approve are: crystalhu.
Reviewers who wrote a comment of /lgtm are: crystalhu, zhangyuxiang0119.

likedislike
CANN-robotCANN-robot成员
2月13日 合入了pull request