已合并
[Feature]:使能LayerwiseDisaggregated边云协同推理特性前提下, 支持配置使能多机推理特性和2p下发的计算图适配 #372
K先生创建于 2月4日
[Feature]:使能LayerwiseDisaggregated边云协同推理特性前提下, 支持配置使能多机推理特性和2p下发的计算图适配 #372
已合并
从已删除 :dev合入到Ascend/MindIE-LLMdev
Pull Request已成功合入, 合并人@ascend-robot
(感谢 K先生 的贡献)ascend-robot
2月4日 评论:
2月4日 评论:
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
以下是根据您提交的修改文件推荐的Reviewer和Committer序列,需各模块评审通过后方可合入.
| Module List | Reviewers | Committers |
|---|---|---|
| repo-Ascend/MindIE-LLM | zzhao2012, winton_he, wbj1207, bowenli, imwangyue | jyoung6652, niushiya, evakkkkkkk, zk123, senxiangms |


2月4日 添加了label:ascend-cla/yes
2月4日 添加了label:needs-issue
ascend-robot
2月4日 评论:
2月4日 评论:
Linking Issue Notice
@kk1994 , the pull request must be linked to at least one issue.
If an issue has already been linked, but the needs-issue label remains, you can remove the label by commenting /check-issue .


examples/atb_models/atb_llm/models/deepseekv2/flash_causal_deepseekv2.py
已过期
@@ -2855,3 +2886,4 @@
28552886 self.encode_op_list[layer].set_kv_cache([k_caches[layer]], [v_caches[layer]])
28562887 self.encode_op_prefix_cache_list[layer].set_kv_cache([k_caches[layer]], [v_caches[layer]])
28572888
函数改名,加上layerwise标志,save_input_param同


此处折叠了44条消息 查看更多
2月7日 添加了label:approvedlgtm
纪涛
2月11日 评论:
2月11日 评论:
/merge


2月11日 添加了label:keeper_approved
ascend-robot
2月11日 评论:
2月11日 评论:
Review Guide
This pull-request passes review.
Committers who wrote a comment of /approve are: Katrina-CXY.
Reviewers who wrote a comment of /lgtm are: Katrina-CXY, zxf_boluochuishui.


2月11日 合入了pull request
合入背景
Fix part of #150
Fix part of #140
修改内容
计算图当前的代码仅适配了DP=1的情况,且编写时新增的部分代码在编写时未考虑到DP>1的情况,需要对上述代码进行检查,对不支持DP=2的代码进行适配。同时需要适配支持QKVDownDP优化。
主要调整包括:
1、DP开启后计算图有变化,当前代码存在未修改DP>1成立的分支,需要进行检查适配。
2、需要对QKVDownDP优化进行适配。
QKVDownDP通过在MOE层中更改AllGather位置起到优化。开启后从MoE第一层至倒数第二层,输出的hidden为未进行AllGather的数据,只有最后一层输出之前会AllGather。由于边侧和云侧卡数不同,为保证边云之间传输正确的hidden,需要在云侧最后一层输出执行了AllGather后的hidden。QKVDownDP在边云场景中应只作用于MoE第一层至云侧倒数第二层。
需要在decoder_model和decoder_layer中新增参数,用于判断是否为云侧最后一层。将QKVDownDP的操作限制在云测最后一层之前。
decoder_model和decoder_layer中的InferShape函数需要对输出的shape进行相应的适配。
资料变更
接口变更
测试结果
CheckList