Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[METAX] Support llama for MX C550 #9186

Merged
merged 3 commits into from
Oct 28, 2024
Merged

Conversation

idontkonwher
Copy link
Contributor

PR types

Others

PR changes

Others

Description

Add MXC550 backend Support for llama

@CLAassistant
Copy link

CLAassistant commented Sep 24, 2024

CLA assistant check
All committers have signed the CLA.

Copy link

codecov bot commented Oct 9, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 52.91%. Comparing base (bc55104) to head (4a9b2ea).
Report is 63 commits behind head on develop.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #9186      +/-   ##
===========================================
- Coverage    53.07%   52.91%   -0.16%     
===========================================
  Files          656      661       +5     
  Lines       106095   106945     +850     
===========================================
+ Hits         56309    56592     +283     
- Misses       49786    50353     +567     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.


```
# PaddleNLP是基于paddlepaddle『飞桨』的自然语言处理和大语言模型(LLM)开发库,存放了基于『飞桨』框架实现的各种大模型,llama2-13B模型也包含其中。为了便于您更好地使用PaddleNLP,您需要clone整个仓库。
git clone /~https://github.com/PaddlePaddle/PaddleNLP.git
Copy link
Collaborator

Choose a reason for hiding this comment

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

这里PaddleNLP的版本需要确认下,或者提供下PaddleNLP在develop分支的commit id

Copy link
Contributor Author

Choose a reason for hiding this comment

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

这里PaddleNLP的版本需要确认下,或者提供下PaddleNLP在develop分支的commit id

好的

# 2. 拉取第三方依赖
git submodule update --init
# 3. 配置环境变量
export MACA_PATH=/real?maca/install/path
Copy link
Collaborator

Choose a reason for hiding this comment

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

real?maca的?的指定的链接是否有问题?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

real?maca的?的指定的链接是否有问题?

此处有typo,应该是/real/maca/install/path

# 您可以使用 --device=/dev/dri/card0 指定仅GPU 0在容器内可见(其它卡同理),--device=/dev/dri 表示所有GPU可见
docker run -it --rm --device=/dev/dri
--device=/dev/mxcd --group-add video -network=host --uts=host --ipc=host --privileged=true --shm-size 128g {image id}
```
Copy link
Collaborator

Choose a reason for hiding this comment

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

这里的镜像是否可以提供docker的下载地址

Copy link
Contributor Author

Choose a reason for hiding this comment

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

这里的镜像是否可以提供docker的下载地址

由于MetaX的相关代码&软件还没有完全开放访问,暂时没有下载链接可以提供,开放后会尽快添加到Readme中

Copy link
Collaborator

Choose a reason for hiding this comment

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

可以尽快提供下docker下载的地址,没有docker镜像看起来也不能使用

Copy link
Contributor Author

Choose a reason for hiding this comment

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

可以尽快提供下docker下载的地址,没有docker镜像看起来也不能使用

是这样的:
如果采用手动安装的话,这个镜像本身并没有太多要求,这种情况下使用 registry.baidubce.com/paddlepaddle/paddle:latest-dev 镜像作为基础镜像,然后用户基于这个镜像安装 MXMACA软件栈 & 编译安装Paddle是可以正常使用的,请问这样可以吗?

Copy link

@onecatcn onecatcn Oct 24, 2024

Choose a reason for hiding this comment

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

可以尽快提供下docker下载的地址,没有docker镜像看起来也不能使用

是这样的: 如果采用手动安装的话,这个镜像本身并没有太多要求,这种情况下使用 registry.baidubce.com/paddlepaddle/paddle:latest-dev 镜像作为基础镜像,然后用户基于这个镜像安装 MXMACA软件栈 & 编译安装Paddle是可以正常使用的,请问这样可以吗?

软件栈暂时没有开源也可以,但是需要提供获取闭源软件的途径。这个在之前paddle-lite的文档中有多个先例:
https://www.paddlepaddle.org.cn/lite/v2.12/demo_guides/mediatek_apu.html

Copy link
Contributor Author

Choose a reason for hiding this comment

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

已添加邮箱和软件中心访问地址供用户获取相关软件栈。

解释一下温故而知新
***********Target**********

***********Output**********
Copy link
Collaborator

Choose a reason for hiding this comment

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

这里的输出结果是不是需要指定成greedy的生成方式,不然输出结果和文档中会不太一致

Copy link
Contributor Author

Choose a reason for hiding this comment

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

好的

@idontkonwher
Copy link
Contributor Author

@wawltor 已按建议进行了修改,麻烦再review一下。

Copy link

@onecatcn onecatcn left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Collaborator

@wawltor wawltor left a comment

Choose a reason for hiding this comment

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

LGTM

@wawltor wawltor merged commit 05ae377 into PaddlePaddle:develop Oct 28, 2024
10 of 12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants