报错显示在不同的流上运行了,建议排查下sglang使用中是否切流了,如果sglang使用没问题,还有这个问题,可以在torchair仓提issue,
https://gitcode.com/Ascend/torchair/issues


报错显示在不同的流上运行了,建议排查下sglang使用中是否切流了,如果sglang使用没问题,还有这个问题,可以在torchair仓提issue,
https://gitcode.com/Ascend/torchair/issues
@huangyunlong2022
多请教一下新的版本下这块有什么已知的新的约束限制吗?
sglang上层是在初始化的时候capture graph的时候出错的,相同代码是在旧版本CANN+2.8.0post1没报错的


先定位下流变化的大概位置,然后缩小范围看是和torchair有关还是和pta有关。


@yuhaiyan @huangyunlong2022
补充一些信息
在capture batch的时候有torch dynamo一些告警:
[rank0]:W0109 01:58:05.384000 3593511 site-packages/torch/_dynamo/convert_frame.py:1016] [0/8] torch._dynamo hit config.recompile_limit (8)
[rank0]:W0109 01:58:05.384000 3593511 site-packages/torch/_dynamo/convert_frame.py:1016] [0/8] function: 'get_masked_input_and_mask' (/home/prof/sglang-master/python/sglang/srt/layers/vocab_parallel_embedding.py:129)
因为怀疑报错是和这个告警相关:
在上层sglang将get_masked_input_and_mask函数的compile装饰器注释掉就能跑通了,函数内部只是在算mask,只有很基础的计算的代码
#@torch.compile(dynamic=True, backend=get_compiler_backend())
def get_masked_input_and_mask(


@yuhaiyan @huangyunlong2022
补充一些信息
在capture batch的时候有torch dynamo一些告警:
[rank0]:W0109 01:58:05.384000 3593511 site-packages/torch/_dynamo/convert_frame.py:1016] [0/8] torch._dynamo hit config.recompile_limit (8)
[rank0]:W0109 01:58:05.384000 3593511 site-packages/torch/_dynamo/convert_frame.py:1016] [0/8] function: 'get_masked_input_and_mask' (/home/prof/sglang-master/python/sglang/srt/layers/vocab_parallel_embedding.py:129)因为怀疑报错是和这个告警相关:
在上层sglang将get_masked_input_and_mask函数的compile装饰器注释掉就能跑通了,函数内部只是在算mask,只有很基础的计算的代码#@torch.compile(dynamic=True, backend=get_compiler_backend()) def get_masked_input_and_mask(
那看起来是和torchair有关,建议在torchair仓提个issue。


在提交新问题之前,请确保您已经在社区中搜索过相关问题,并使用了社区中提供的资源/工具后,仍未找到满意的解决方式。
⚠️ 安全信息提醒:请仔细检查提供的文本内容,确保其不包含敏感数据信息,包括但不限于:
在分享配置信息或代码示例时,请将敏感信息脱敏处理,或使用
<TOKEN>等占位符替代原有内容。环境信息
环境信息:
🐛 问题描述
报错显示如下
2.8.0post1版本接CANN 8.3RC1版本没有这个报错,但是有其他计算结果NAN/graph.replay()等报错,8.5尝试torch-npu 2.8.0post3也有相同报错
欢迎加入社区,感谢您对社区的贡献 🎉!