name | about | labels |
---|---|---|
Bug Report | Use this template for reporting a bug | kind/bug |
pix2pix等多个教程网络在910A/910B上打印告警信息:For 'context.set_context' in Ascend backend, the backend is already initialized, please set it before the definition of any Tensor and Parameter, and the instantiation and execution of any operation and net, otherwise the settings may not take effect.
教程地址:https://www.mindspore.cn/tutorials/application/zh-CN/master/generative/cyclegan.html
Ascend
/GPU
/CPU
) / 硬件环境:Please delete the backend not involved / 请删除不涉及的后端:
/device ascend
Software Environment / 软件环境 (Mandatory / 必填):
-- MindSpore version (e.g., 1.7.0.Bxxx) :
-- Python version (e.g., Python 3.7.5) :
-- OS platform and distribution (e.g., Linux Ubuntu 16.04):
-- GCC/Compiler version (if compiled from source):
失败版本:r2.3_20240417_d51c17c7 Milan_C17/20240414
成功版本:r2.3_aa16e0b8 Milan_C17/20240408
Excute Mode / 执行模式 (Mandatory / 必填)(PyNative
/Graph
):
Please delete the mode not involved / 请删除不涉及的模式:
/mode pynative
/mode graph
用例路径:solution_test/cases/03subject_test/06document/02network_cases
关联用例:test_ms_tutorial_cv_cyclegan_0001.py
网络训练成功,日志中不存在告警日志
WARNING日志重复次数 WARNING日志
1 mindspore/ccsrc/runtime/hardware/device_context_manager.cc:466] GetDeviceContext] Device context of device Ascend is not created yet.
1 mindspore/context.py:1098] For 'context.set_context' in Ascend backend, the backend is already initialized, please set it before the definition of any Tensor and Parameter, and the instantiation and execution of any operation and net, otherwise the settings may not take effect.
1 mindspore/hal/device.py:155] Backend Ascend is not created yet.
走给常哲瑞
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。
感谢您的提问,您可以评论//mindspore-assistant更快获取帮助:
和测试对齐,此问题只在r2.3分支存在
对于新出现的这两个warning,将日志级别改为INFO:
mindspore/ccsrc/runtime/hardware/device_context_manager.cc:466] GetDeviceContext] Device context of device Ascend is not created yet.
mindspore/hal/device.py:155] Backend Ascend is not created yet.
pr :
https://e.gitee.com/mind_spore/repos/mindspore/mindspore/pulls/68864
对于这个warning,请修改脚本解决
第一部分修改日志级别已上库,转给相关责任人修改脚本
set_context为测试用例添加的,由测试修改后回归。
登录 后才可以发表评论