tensorflow: bazel still report error: name 'http_archive' is not defined
I’m experiencing the same error described in issue #27189, when I try to build TF v1.12.2 using Bazel 0.25.2 on a Jetson TX2
$ export TF_NEED_CUDA=1
$ export TF_CUDA_VERSION=9.0
$ export CUDA_TOOLKIT_PATH=/usr/local/cuda
$ export TF_CUDNN_VERSION=7.1.5
$ export CUDNN_INSTALL_PATH=/usr/lib/aarch64-linux-gnu/
$ export TF_CUDA_COMPUTE_CAPABILITIES=6.2
$ bazel build --config=opt --config=cuda //tensorflow/tools/pip_package:build_pip_package
WARNING: The following configs were expanded more than once: [cuda]. For repeatable flags, repeats are counted twice and may lead to unexpected behavior.
ERROR: /home/nvidia/git/tensorflow/WORKSPACE:3:1: name 'http_archive' is not defined
ERROR: Error evaluating WORKSPACE file
ERROR: error loading package '': Encountered error while reading extension file 'closure/defs.bzl': no such package '@io_bazel_rules_closure//closure': error loading package 'external': Could not load //external package
ERROR: error loading package '': Encountered error while reading extension file 'closure/defs.bzl': no such package '@io_bazel_rules_closure//closure': error loading package 'external': Could not load //external package
INFO: Elapsed time: 0.222s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (0 packages loaded)
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 20
@mihaimaruseac In that case, then I’m going to go with the TF-1.13.1 precompiled binary version from Nvidia and save myself from the trouble of spending 6+ hours building it from source. Thank you for time and assistance with this.
With -mfpu=neon removed, the build ran longer, BUT after almost 6 hours running, then it failed with some kind of native TensorFlow runtime error:
Ok, so for AArch64
-mfpu=neonis not needed as neon is mandatory and included by default. Still dubious that the compiler would complain instead of silently ignoring but not the topic to discuss that here.I think it is better to run
./configureagain as you changed some options. Though these seem to be in Bazel files, so probably there won’t be any change. Better safe though, so I recommend rerunning.I got builds taking 4-5 hours at one point, it all depends on how many CPUs and how powerful they are. The codebase is quite big.
You can build without NCCL. In fact, many times I built without any GPU at all.
I guess the option forward is to try removing
"-mpfu=neon"lines from https://github.com/tensorflow/tensorflow/blob/6b634657d8ff1355132c3838271e4f569d1ffaba/tensorflow/contrib/lite/kernels/internal/BUILD#L21-L37