Skip to content

hack_ai团队作品提交(patches.zip我的git识别不了,只能改下文件名)#118

Open
zhouyifeng888 wants to merge 3 commits intomindspore-lab:devfrom
zhouyifeng888:dev
Open

hack_ai团队作品提交(patches.zip我的git识别不了,只能改下文件名)#118
zhouyifeng888 wants to merge 3 commits intomindspore-lab:devfrom
zhouyifeng888:dev

Conversation

@zhouyifeng888
Copy link
Copy Markdown

hack_ai团队作品提交(patches.zip我的git识别不了,只能改下文件名)

Copy link
Copy Markdown
Collaborator

@qhzhuang qhzhuang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

为什么提交了一个docx格式的README.
日志可以放到README.md的表里面
参考: https://github.com/mindspore-lab/competition/pull/111/files
patch文件手动git add patch.zip呢, 或者改下gitignore 取消对zip的ignore

@zhouyifeng888
Copy link
Copy Markdown
Author

已修改,那个zip包不知道为何我的git就是识别不了,就是没法git add,各种操作都不行,但如果打包的不是补丁文件就可以,所以最后改成文件夹提交了


# 1.最终提交的方案:

把每一层的moe 每个专家的权重事先都合并起来,然后推理的时候就执行一次;从而避开了每个专家需要单独执行,以及帅选出需要执行的专家的逻辑,动态图执行的大部分耗时都在python时间上(一些python逻辑,调用相关python api触发算子下发等操作),即cpu耗时,在鲲鹏环境中,这个特性尤其明显,哪怕绑核后,相比x86环境这个耗时也更加巨大;而该方案,避开了刷选专家的逻辑,即避开了很多相关api的调用,节省了大量的python时间,以及所有专家都合并起来了,也就是不需要循环调用每个专家,python api的调用次数也大大减少,尤其prefill阶段,自然也节省了大量的python时间;还有,原本的实现中,挑选moe的逻辑用到了nonzero等比较耗时的算子,该方案由于没有挑选逻辑,所以也避开了nonzero这样非常耗时的算子;
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

筛选, not 帅选

@@ -0,0 +1,4 @@
任务执行结果:
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个文件可以去掉, 把内容挪到README.md里并做下说明是判题机器执行结果即可

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

已修复

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants