当前位置:网站首页>MindSpore:图算融合报错
MindSpore:图算融合报错
2022-08-04 09:03:00 【小乐快乐】
问题描述:
在mindspore1.1.1上做图算融合,硬件环境是Ascend 910,程序没有问题,添加运行图算融合(enable_graph_kernel=True)参数之后程序报错:
ms.context.set_context(mode=ms.context.GRAPH_MODE, device_target=args.device_target,
save_graphs=False, max_call_depth=10000, device_id=args.device_id, enable_graph_kernel=True)
报错记录如下:
Traceback (most recent call last):
File "/opt/python3.7.5/lib/python3.7/site-packages/mindspore/_extends/parallel_compile/akg_compiler/compiler.py", line 35, in <module>
run_compiler(sys.argv[1])
File "/opt/python3.7.5/lib/python3.7/site-packages/mindspore/_extends/parallel_compile/akg_compiler/compiler.py", line 28, in run_compiler
p = __import__("akg", globals(), locals(), ['ms'], 0)
File "/opt/python3.7.5/lib/python3.7/site-packages/akg/__init__.py", line 84, in <module>
from . import autodiff
File "/opt/python3.7.5/lib/python3.7/site-packages/akg/autodiff.py", line 19, in <module>
from akg.tvm._ffi.function import _init_api
File "<frozen importlib._bootstrap>", line 983, in _find_and_load
File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 668, in _load_unlocked
File "<frozen importlib._bootstrap>", line 638, in _load_backward_compatible
File "/opt/python3.7.5/lib/python3.7/site-packages/akg/__init__.py", line 62, in load_module
__import__(self.__rname, globals(), locals())
File "/opt/python3.7.5/lib/python3.7/site-packages/akg/tvm/__init__.py", line 27, in <module>
from . import tensor
File "/opt/python3.7.5/lib/python3.7/site-packages/akg/tvm/tensor.py", line 20, in <module>
from ._ffi.node import NodeBase, NodeGeneric, register_node, convert_to_node
File "/opt/python3.7.5/lib/python3.7/site-packages/akg/tvm/_ffi/node.py", line 24, in <module>
from .object import Object, register_object, _set_class_node
File "/opt/python3.7.5/lib/python3.7/site-packages/akg/tvm/_ffi/object.py", line 23, in <module>
from .base import _FFI_MODE, _RUNTIME_ONLY, check_call, _LIB, c_str
File "/opt/python3.7.5/lib/python3.7/site-packages/akg/tvm/_ffi/base.py", line 81, in <module>
_LIB, _LIB_NAME = _load_lib()
File "/opt/python3.7.5/lib/python3.7/site-packages/akg/tvm/_ffi/base.py", line 73, in _load_lib
lib = ctypes.CDLL(lib_path[0], ctypes.RTLD_GLOBAL)
File "/opt/python3.7.5/lib/python3.7/ctypes/__init__.py", line 364, in __init__
self._handle = _dlopen(self._name, mode)
OSError: /opt/python3.7.5/lib/python3.7/site-packages/mindspore/lib/libakg.so: undefined symbol: pthread_atfork
Traceback (most recent call last):
Traceback (most recent call last):
File "/opt/python3.7.5/lib/python3.7/site-packages/mindspore/_extends/parallel_compile/akg_compiler/compiler.py", line 35, in <module>
File "/opt/python3.7.5/lib/python3.7/site-packages/mindspore/_extends/parallel_compile/akg_compiler/compiler.py", line 35, in <module>
run_compiler(sys.argv[1])
run_compiler(sys.argv[1])
File "/opt/python3.7.5/lib/python3.7/site-packages/mindspore/_extends/parallel_compile/akg_compiler/compiler.py", line 28, in run_compiler
File "/opt/python3.7.5/lib/python3.7/site-packages/mindspore/_extends/parallel_compile/akg_compiler/compiler.py", line 28, in run_compiler
p = __import__("akg", globals(), locals(), ['ms'], 0)
p = __import__("akg", globals(), locals(), ['ms'], 0)
这个报错记录太长了,超过帖子最大字数限制,我把报错记录放在附件error.txt中了
求问有哪位大神指导这个问题如何解决吗?
解决方案:
这个问题的原因在于使用了高版本的gcc编译akg时找不到pthread_atfork。
pthread_atfork是POSIX标准,在编译时要加上-pthread
-lpthread是老版本的gcc编译器用的,在新版本中应该用-pthread取代-lpthread
可以在akg 的 cmakelist下的target_link_libraries增加pthread重新编译一次
边栏推荐
- 【云驻共创】HCSD 大咖直播–就业指南
- Libpq 是否支持读写分离配置
- 【Attention】Dual Attention(DANet) & Fully Attention(FLA)
- Interpretation of new features | MySQL 8.0 online adjustment REDO
- [Punctuality Atom STM32 Serial] Chapter 2 STM32 Introduction Excerpted from [Punctual Atom] MiniPro STM32H750 Development Guide_V1.1
- yolo x 跑起来,详细的不行,且内含800错误解决办法
- ShowMeAI —— Show u 三连
- After four years of outsourcing, the autumn recruits finally landed
- js - the first letter that appears twice
- 2022-08-02 Analyze RK817 output 32k clock PMIC_32KOUT_WIFI to WiFi module clock register devm_clk_hw_register
猜你喜欢

去掉js代码文件所有注释

binder通信实现
![Detailed explanation of MSTP protocol configuration on Layer 3 switches [Huawei eNSP experiment]](/img/97/6c3662ef36b02bc42eec95abaa6bc5.png)
Detailed explanation of MSTP protocol configuration on Layer 3 switches [Huawei eNSP experiment]
![Detailed Explanation of Addresses Delivered by DHCP on Routing/Layer 3 Switches [Huawei eNSP]](/img/9c/b4ebe608cf639b8348adc1f1cc71c8.png)
Detailed Explanation of Addresses Delivered by DHCP on Routing/Layer 3 Switches [Huawei eNSP]

Apache Druid 实时分析数据库入门介绍

【论文笔记】Dynamic Convolution: Attention over Convolution Kernels

菲沃泰科创板上市:市值123亿 宗坚赵静艳夫妇身价76亿

After four years of outsourcing, the autumn recruits finally landed

JSP基本语法

2022年制冷与空调设备运行操作特种作业证考试题库及模拟考试
随机推荐
【高并发基石】多线程、守护线程、线程安全、线程同步、互斥锁
蜜芽CEO刘楠:垂直电商黄金时代已落幕 坚定转型品牌之路
抬升市场投资情绪,若羽臣是否还需“自身硬”?
区分惯性环节与延迟环节
[Punctuality Atom STM32 Serial] Chapter 4 STM32 First Experience Excerpted from [Punctual Atom] MiniPro STM32H750 Development Guide_V1.1
SQL后计算的利器
TiFlash 源码阅读(五) DeltaTree 存储引擎设计及实现分析 - Part 2
加降息与BTC流动性事件策略研究
I am 37 this year, and I was rushed by a big factory to...
三层交换机/路由器OSPF配置详解【华为eNSP实验】
spark算子讲解
【论文笔记】Delving into the Estimation Shift of Batch Normalization in a Network
并发编程之生产者和消费者问题
Interpretation of new features | MySQL 8.0 online adjustment REDO
cannot import name 'import_string' from 'werkzeug' [bug solution]
ShuffleNet v2 network structure reproduction (Pytorch version)
cannot import name ‘import_string‘ from ‘werkzeug‘【bug解决】
路由/三层交换机DHCP下发地址详解【华为eNSP】
今年37了,被大厂抢着要...
DeLighT:深度和轻量化的Transformer