香橙派AI pro 运行bert内存占用不正常,无法运行
收藏回复举报
香橙派AI pro 运行bert内存占用不正常,无法运行
t('forum.solved') 已解决
新人帖
发表于2024-09-18 16:20:46
0 查看

1.Describe the current behavior / 问题描述 (Mandatory / 必填)

在香橙派AIpro上使用NPU运行bert进行classifier任务时会在推理时运行到model.predict()时内存占用激增占满内存空间,使用CPU运行正常

2.Environment / 环境信息 (Mandatory / 必填)

  • Hardware Environment / 硬件环境(Mandatory / 必填):
后端类型硬件具体类别
Ascend310B4
CPUARM

npu-smi info

  • Software Environment / 软件环境 (Mandatory / 必填):
SoftwareVersion(根据实际修改,必填)
固件23.0.0
MindSporeMindSpore 2.2.14
CANN7.0.0
PythonPython 3.7
OS platformUbuntu 20.04

3.Related testcase / 关联用例 (Mandatory / 必填)

models: Models of MindSpore - Gitee.com

run_classifier.py

4.Steps to reproduce the issue / 重现步骤 (Mandatory / 必填)

使用附录脚本运行,模型选用https://download.mindspore.cn/models/r1.9/bert_base_ascend_v190_zhwiki_official_nlp_bs256_acc91.72_recall95.06_F1score93.36.ckpt

5.Describe the expected behavior / 预期结果 (Mandatory / 必填)

【预期结果】:运行正常

6.Related log / screenshot / 日志 / 截图 (Mandatory / 必填)

刚开始时内存占用 刚开始时内存占用 运行到model.predict时占用,最终会占满全部内存空间 运行到model.predict时占用,最终会占满全部内存空间

7.Special notes for this issue/备注 (Optional / 选填)

原issue

我要发帖子