mirror of
https://github.com/kvcache-ai/ktransformers.git
synced 2026-11-05 01:07:28 +00:00
[GH-ISSUE #167] 支持国产GPU/华为昇腾NPU需要做哪些工作? #91
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
kvcache-ai/ktransformers#91
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @xxchen86 on GitHub (Feb 12, 2025).
Original GitHub issue: https://github.com/kvcache-ai/ktransformers/issues/167
我们意图在华为Ascend 910B上进行Deepseek-R1 671B的推理,请问适配新的硬件需要做哪些工作?
@Azure-Tang commented on GitHub (Feb 12, 2025):
我们目前没有昇腾的设备和懂昇腾硬件的同学,所以可能没办法支持您做这个。您可以看一下marlin算子是否可以在昇腾卡上运算?
https://github.com/IST-DASLab/marlin
@QwertyJack commented on GitHub (Feb 12, 2025):
我这有,怎么联系?wx群满了
@Azure-Tang commented on GitHub (Feb 13, 2025):
非常感谢您🙏不过这个支持应该不会在短期计划中。如果想加群的话我们更新了主页的二维码
@Atream commented on GitHub (Feb 13, 2025):
wx群已更新,我们也有同学在研究国产卡上的算子优化但人手和经验严重不足,短期内不会支持,支持非CUDA卡需要开源社区的帮助
@xxchen86 commented on GitHub (Feb 14, 2025):
所以 KTransformer 和硬件之间的接口就只是 Marlin 的矩阵乘算子吗?如果要适配新的硬件,是不是把特定硬件实现的 FP16xINT4 的矩阵乘算子接入 KTransformer 就可以了呢?
@Azure-Tang commented on GitHub (Feb 14, 2025):
看上去是的,您可以仿造我们的linearMarlin算子(在linear.py里)构造一个新的算子,然后可能需要注意一下load权重部分,我们是将gguf dequant后再用marlin pack成marlin的权重。这部分如果有不懂的欢迎交流
@Atream commented on GitHub (Feb 14, 2025):
还有CUDA Graph这种计算图的优化,因为使用了python,不使用计算图优化会导致python成为性能瓶颈
@bachelor-dou commented on GitHub (Feb 20, 2025):
昇腾NPU 配套的CANN支持计算图优化
@bachelor-dou commented on GitHub (Feb 20, 2025):
目前来看,关键在于marlin算子的实现
@xxchen86 commented on GitHub (Feb 20, 2025):
感谢大家的回复,鄙人结合各位的建议和对KTransformer源码的分析,总结出以下适配新的硬件组合可能要解决的问题:
@xxchen86 commented on GitHub (Feb 20, 2025):
针对国产卡的适配问题,欢迎大家一起讨论!
@xiaods commented on GitHub (Mar 19, 2025):
KTransformers是当前最火热的最低成本的Deepseek满血版推理方案。KunLun AI Space大模型加速引擎在此基础上完成两项重大技术突破:移植KTransformers到鲲鹏+昇腾全国产生态,同时使用自研算子替代Marlin算子,实现单张昇腾300I Duo推理卡高效运行满血版DeepSeek大模型
https://mp.weixin.qq.com/s/amGL613UMF-seH9pkzZI_g
@handerason commented on GitHub (Mar 20, 2025):
大佬您好,请问有实现的过程嘛?可以复现吗?
@bachelor-dou commented on GitHub (Mar 20, 2025):
目前有代码公布计划时间吗?
@Thymos2027 commented on GitHub (Apr 17, 2025):
同求
@hoperun300339 commented on GitHub (May 13, 2025):
同求
@Zha-Miku commented on GitHub (Sep 11, 2025):
现在还能支持910b4的推理吗
@zzc98 commented on GitHub (Oct 15, 2025):
还有支持Ascend的计划吗,我看之前说 v0.2.4 就会支持,readme中也写了,但是没有看到任何与ascend相关的代码或文档