alibaba / alibaba/BladeDISC

meet error when build_from_source_code

Open
#1,024 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
933
Forks
169
PR merge metrics
No merged PRs in 30d

Description

hi
I update the source code(commit Id: f6505c46b38f132af54fb5b39), and do it as below steps:
1. docker run --rm -it -v $PWD:/disc bladedisc/bladedisc:latest-devel-cuda11.0 bash
2. config the env as belows:

export PATH=/root/.bazel/bin/:$PATH
export TORCH_BLADE_BUILD_WITH_CUDA_SUPPORT=OFF
export TORCH_BLADE_USE_PLATFORM_ALIBABA=OFF
export TORCH_BLADE_CI_BUILD_TORCH_VERSION=1.12.0+cpu

3. cd pytorch_blade && bash ./scripts/build_pytorch_blade.sh
4. error log:

Loading:
Loading: 0 packages loaded
ERROR: error loading package '': Label '@torch-mlir-importer//utils/bazel:configure.bzl' is invalid because 'utils/bazel' is not a package; perhaps you meant to put the colon here: '@torch-mlir-importer//:utils/bazel/configure.bzl'?
INFO: Elapsed time: 0.148s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (0 packages loaded)
ERROR: Couldn't start the build. Unable to run tests
FAILED: Build did NOT complete successfully (0 packages loaded)
Traceback (most recent call last):
File "setup.py", line 151, in
setup(
File "/usr/lib/python3/dist-packages/setuptools/__init__.py", line 129, in setup
return distutils.core.setup(**attrs)
File "/usr/lib/python3.8/distutils/core.py", line 148, in setup
dist.run_commands()
File "/usr/lib/python3.8/distutils/dist.py", line 966, in run_commands
self.run_command(cmd)
File "/usr/lib/python3.8/distutils/dist.py", line 985, in run_command
cmd_obj.run()
File "setup.py", line 107, in run
self.cpp_run()
File "setup.py", line 91, in cpp_run
build.test()
File "/disc/pytorch_blade/bazel_build.py", line 282, in test
subprocess.check_call(test_cmd, shell=True, env=env, executable="/bin/bash")
File "/usr/lib/python3.8/subprocess.py", line 364, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command 'set -e; set -o pipefail; source .bazel_pyenv/bin/activate; bazel test --action_env PYTHON_BIN_PATH=/usr/bin/python3 --action_env BAZEL_LINKLIBS=-lstdc++ --action_env CC=/usr/bin/gcc --action_env CXX=/usr/bin/g++ --action_env DISC_FOREIGN_MAKE_JOBS=32 --copt=-DPYTORCH_VERSION_STRING=\"1.12.0+cpu\" --copt=-DPYTORCH_MAJOR_VERSION=1 --copt=-DPYTORCH_MINOR_VERSION=12 --copt=-DTORCH_BLADE_CUDA_VERSION=None --action_env TORCH_BLADE_TORCH_INSTALL_PATH=/usr/local/lib/python3.8/dist-packages/torch --copt=-DPYBIND11_COMPILER_TYPE=\"_gcc\" --copt=-DPYBIND11_STDLIB=\"_libstdcpp\" --copt=-DPYBIND11_BUILD_ABI=\"_cxxabi1013\" --config=torch_ltc_disc_backend --config=torch_debug --config=torch_enable_quantization --config=torch_cxx11abi_0 --config=torch_x86 //tests/mhlo/... //pytorch_blade:torch_blade_test_suite //tests/torch-disc-pdll/tests/... //tests/torchscript/...' returned non-zero exit status 1.

Contributor guide

No contributing guide indexed for this repository

Research direction

Reproduce the source build with the Docker command and environment variables in the issue. Start with scripts/build_pytorch_blade.sh and bazel_build.py, then trace the invalid @torch-mlir-importer//utils/bazel:configure.bzl label shown in the Bazel log. Done means the build and the requested Bazel tests complete successfully.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, docker, python, pytorch
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.