pcg-mlp / KsanaLLM

Other
257 stars 28 forks source link

910B上配置项目失败 #23

Closed dengyingxu closed 1 month ago

dengyingxu commented 1 month ago

描述 在尝试配置项目时遇到了一个错误。具体步骤和错误信息如下。

重现步骤 克隆项目仓库并进入项目目录。

运行以下命令以配置项目:

cmake -DWITH_TESTING=ON -DWITH_CUDA=OFF -DWITH_ACL=ON .. && make -j32 遇到以下错误信息:

[root@A03-R40-I18-71-0001195 build]# cmake -DWITH_TESTING=ON -DWITH_CUDA=OFF -DWITH_ACL=ON .. && make -j32 -- Running submodule build to fetch LLM_kernels -- SOC_VERSION: ascend910b1 -- RUN_MODE: npu -- ASCEND_CANN_PACKAGE_PATH: /usr/local/Ascend/ascend-toolkit/latest -- CCE_CMAKE_PATH: /export/home/dengyingxu1/KsanaLLM/3rdparty/LLM_kernels/cmake/module -- ASCEND_INSTALL_PATH: /usr/local/Ascend/ascend-toolkit/latest -- ASCEND_RUN_MODE: ONBOARD -- ASCEND_CORE_TYPE: AiCore -- ASCEND_PRODUCT_TYPE: ascend910 -- Using ATB 1.0.T59.B010 at /usr/local/Ascend/mindie/latest/mindie-rt/mindie-atb/atb -- Running submodule update to fetch half You need to run this command from the toplevel of the working tree. CMake Error at 3rdparty/LLM_kernels/CMakeLists.txt:87 (message): git submodule update --init 3rdparty/half failed with 1, please checkout cutlass submodule

-- Configuring incomplete, errors occurred! 预期行为 项目应成功配置并准备好进行编译。

实际行为 配置过程失败,出现错误提示 git submodule update --init 3rdparty/half failed with 1, please checkout cutlass submodule。

环境 操作系统:CentOS 硬件:Ascend 910 其他信息 尝试运行以下命令以手动更新子模块,但仍然遇到相同的错误:

git submodule update --init 3rdparty/half 希望能尽快解决这个问题,谢谢!

pcg-mlp commented 1 month ago

从你的硬件信息-- ASCEND_CORE_TYPE: AiCore来看,你的硬件应该是老架构的整体AiCore结构core_type_list=AICore。 在华为的软件里面,对910B是单独对待的,算子和调用逻辑都是独立分支。 目前一念支持的是分离架构的芯片core_type_list=CubeCore,VectorCore,具体芯片型号是910B2以后的版本。

image
dengyingxu commented 1 month ago
image

请问,我该如何查看我的core_type_list呢?我的TPU name是910B2C

dengyingxu commented 1 month ago

请问您图片中的内容是如何看的呢?

pcg-mlp commented 1 month ago

以我们这里的CANN7.0的环境为例:/usr/local/Ascend/ascend-toolkit/7.0.0/compiler/data/platform_config

pcg-mlp commented 1 month ago

grep -E "core_type_list" Ascend910*

pcg-mlp commented 1 month ago

image 请问,我该如何查看我的core_type_list呢?我的TPU name是910B2C

你这个硬件应该是没有问题的。可以试试清理了环境重新编译

dengyingxu commented 1 month ago
image

我的python 是3.10 cmake 是3.30.2 ,我仍然不能cmake成功。官方推荐python,cmake版本是多少呢?

dengyingxu commented 1 month ago

我使用的是mindie的镜像,名字大概为:mindie-server-ascend-x86-910b-dev-530 修改cmake命令如下: cmake -DWITH_TESTING=ON -DWITH_CUDA=OFF -DWITH_ACL=ON .. -DPYTHON_INCLUDE_DIR=$(python -c "from distutils.sysconfig import get_python_inc; print(get_python_inc())") -DPYTHON_LIBRARY=$(python -c "import distutils.sysconfig as sysconfig; print(sysconfig.get_config_var('LIBDIR'))") -DPYTHON_EXECUTABLE:FILEPATH=which python 也改了-- SOC_VERSION: ascend910b1、-- ASCEND_CORE_TYPE: AiCore等参数在CMakeLists.txt文件中,改成我的910b2c型号了。

之后上述问题解决了,但是之后出现新的问题如下:

image

我是十分困惑的,是不是我的出发点哪里有问题?他不应该是如此麻烦的