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

执行编译时报错 #1271

Closed
Piterang opened this issue May 30, 2024 · 6 comments
Closed

执行编译时报错 #1271

Piterang opened this issue May 30, 2024 · 6 comments
Assignees

Comments

@Piterang
Copy link

+++ dirname tools/compile.sh
++ cd tools/../
++ pwd

  • SOURCE_ROOT=/Work/PaddleCustomDevice/backends/npu
  • mkdir -p /Work/PaddleCustomDevice/backends/npu/build
  • cd /Work/PaddleCustomDevice/backends/npu/build
    ++ uname -i
  • arch=aarch64
  • '[' aarch64 == x86_64 ']'
  • WITH_MKL=OFF
  • WITH_ARM=ON
  • WITH_ATB=OFF
  • '[' -n '' ']'
  • cat
    ========================================
    Configuring cmake in build ...
    -DCMAKE_BUILD_TYPE=Release
    -DWITH_TESTING=OFF
    -DWITH_MKL=OFF
    -DWITH_ARM=ON
    -DWITH_ATB=OFF
    -DON_INFER=OFF
    -DWITH_COVERAGE=OFF
    ========================================
  • set +e
  • cmake .. -DCMAKE_BUILD_TYPE=Release -DWITH_TESTING=OFF -DWITH_MKL=OFF -DWITH_ARM=ON -DWITH_ATB=OFF -DON_INFER=OFF -DWITH_COVERAGE=OFF -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
    WANRINGCannot find core_avx.so, using core_noavx.so instead.
    FATALcore_noavx.so NOT found in /usr/local/python3.7.5/lib/python3.7/site-packages/paddle/base/
    -- Run 'git submodule update --init Paddle' in /Work/PaddleCustomDevice
    -- PADDLE_SOURCE_DIR=/Work/PaddleCustomDevice/Paddle
    -- Paddle version is 0.0.0
    -- FWKACLLIB_INC_DIR /usr/local/Ascend/ascend-toolkit/latest/fwkacllib/include
    -- ASCEND_CL_DIR /usr/local/Ascend/ascend-toolkit/latest/fwkacllib/lib64
    -- ATB_INC_DIR /usr/local/Ascend/atb/latest/atb/include
    -- Current Ascend Toolkit version is 5.1.RC2
    -- Current Ascend Driver version is 20.1.0
    -- CXX compiler: /usr/bin/c++, version: GNU 7.5.0
    -- C compiler: /usr/bin/cc, version: GNU 7.5.0
    -- AR tools: /usr/bin/ar
    -- CMAKE_CXX_FLAGS: -Wno-narrowing -Wno-terminate -Wno-write-strings -Wno-return-type -D_GLIBCXX_USE_CXX11_ABI=1
    -- CUSTOM_OPERATOR_SRCS=custom_op/fused_allgather_mm.cc;custom_op/fused_attention_npu.cc;custom_op/fused_mm_allreduce.cc;custom_op/fused_mm_reduce_scatter.cc;custom_op/fused_rms_norm_npu.cc;custom_op/fused_rope_npu.cc;custom_op/llama_infer/atb_ops/atb_layers/fused_blha_layer.cc;custom_op/llama_infer/atb_ops/atb_layers/fused_lm_head_layer.cc;custom_op/llama_infer/atb_ops/atb_layers/linear.cc;custom_op/llama_infer/atb_ops/atb_layers/mixed_gate_up_act.cc;custom_op/llama_infer/atb_ops/atb_layers/qkv_split.cc;custom_op/llama_infer/atb_ops/atb_layers/runner.cc;custom_op/llama_infer/atb_ops/atb_layers/smooth_quant.cc;custom_op/llama_infer/atb_ops/fused_blha_layer_op.cc;custom_op/llama_infer/atb_ops/fused_blha_layer_op_utils.cc;custom_op/llama_infer/atb_ops/fused_lm_head_op.cc;custom_op/llama_infer/atb_ops/remove_padding_op.cc;custom_op/llama_infer/dequant_int8.cc;custom_op/llama_infer/encode_rotary_qk.cc;custom_op/llama_infer/fused_get_rope.cc;custom_op/llama_infer/get_output.cc;custom_op/llama_infer/get_padding_offset.cc;custom_op/llama_infer/get_padding_offset_v2.cc;custom_op/llama_infer/qkv_transpose_split.cc;custom_op/llama_infer/quant_int8.cc;custom_op/llama_infer/rebuild_padding.cc;custom_op/llama_infer/rebuild_padding_v2.cc;custom_op/llama_infer/save_with_output.cc;custom_op/llama_infer/save_with_output_msg.cc;custom_op/llama_infer/set_value_by_flags.cc;custom_op/llama_infer/set_value_by_flags_v2.cc;custom_op/llama_infer/step.cc;custom_op/llama_infer/stop_generation_multi_ends.cc;custom_op/llama_infer/stop_generation_multi_ends_v2.cc;custom_op/llama_infer/token_penalty_multi_scores.cc;custom_op/llama_infer/token_penalty_multi_scores_v2.cc;custom_op/llama_infer/transpose_removing_padding.cc;custom_op/llama_infer/update_inputs.cc;custom_op/llama_infer/write_cache_kv.cc;custom_op/llama_infer/write_int8_cache_kv.cc;custom_op/my_add_n_op.cc
    -- Run 'git submodule update --init gflags' in /Work/PaddleCustomDevice/Paddle/third_party
    -- Run 'git submodule update --init glog' in /Work/PaddleCustomDevice/Paddle/third_party
    -- Run 'git submodule update --init pybind' in /Work/PaddleCustomDevice/Paddle/third_party
    -- Git commit id is: 9d31813
    -- Custom op git commit id is: 9d31813
    -- Configuring done (0.5s)
    CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
    Please set them or make sure they are set and tested correctly in the CMake files:
    PADDLE_CORE_LIB
    linked by target "paddle-custom-npu" in directory /Work/PaddleCustomDevice/backends/npu

-- Generating done (0.1s)
CMake Generate step failed. Build files cannot be regenerated correctly.

  • cmake_error=1
  • '[' 1 '!=' 0 ']'
  • echo 'CMake Error Found !!!'
    CMake Error Found !!!
  • exit 7
@YanhuiDua
Copy link
Collaborator

你好,请尝试下先运行 python -c "import paddle;paddle.utils.run_check()"检查paddle是否安装好,且Paddle版本需要与PaddleCustomDevice版本对应

@Piterang
Copy link
Author

你好,请尝试先运行 python -c "import paddle;paddle.utils.run_check()"检查paddle是否安装好,且Paddle版本需要与PaddleCustomDevice版本对应

我装的paddle版本是1.0.2,使用的python版本是3.7,使用教程中的paddlepaddle安装指令无法安装。

@YanhuiDua
Copy link
Collaborator

YanhuiDua commented May 31, 2024

你好,paddle1.0.2的版本太低了,不建议使用,可以参考这个issue #1258 和官方文档https://github.com/PaddlePaddle/PaddleCustomDevice/blob/develop/backends/npu/README_cn.md ,先使用官方镜像,安装2.6或者develop的paddle,再编译PaddleCustomDevice。

@YanhuiDua
Copy link
Collaborator

你好,请问安装还有问题嘛?

@Piterang
Copy link
Author

你好,请问安装还有问题嘛?

成功安装了,感谢!

@qili93
Copy link
Collaborator

qili93 commented Jun 18, 2024

Close issue, thanks!

@qili93 qili93 closed this as completed Jun 18, 2024
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

No branches or pull requests

4 participants