tensorflow: Errors while building Tensorflow 1.12
System information
- OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Void Linux glibc x86_64
- TensorFlow installed from (source or binary): Source
- TensorFlow version: r1.12
- Python version: 3.6
- Installed using virtualenv? pip? conda?: pip, no virtualenv
- Bazel version (if compiling from source): 0.22
- GCC/Compiler version (if compiling from source): 8.2.0
- CUDA/cuDNN version: No
- GPU model and memory: None
Describe the problem
Hello guys, I’m trying to build TF in a non Debian based distro. But what I’m getting is this error, as referrenced by this windows build from source, especially related to eigen.
Provide the exact sequence of commands / steps that you executed before running into the problem
bazel build --incompatible_remove_native_http_archive=false --config=opt --copt=-mavx --copt=-mavx2 --config=monolithic //tensorflow/tools/pip_package:build_pip_package
INFO: Invocation ID: 851c2110-08b2-4ed8-a7b0-4c995b8388e9
DEBUG: /home/neel/.cache/bazel/_bazel_neel/e655abc18ce719a580533b95739e1032/external/build_bazel_rules_apple/apple/repositories.bzl:35:5:
WARNING: `build_bazel_rules_apple` depends on `bazel_skylib` loaded from https://github.com/bazelbuild/bazel-skylib.git (tag 0.6.0), but we have detected it already loaded into your workspace from None (tag None). You may run into compatibility issues. To silence this warning, pass `ignore_version_differences = True` to `apple_rules_dependencies()`.
INFO: Build options --compiler and --cpu have changed, discarding analysis cache.
ERROR: /home/neel/Programming_Workspace/Not-My-Repos/tensorflow/third_party/eigen3/BUILD:34:1: no such package '@eigen_archive//': Traceback (most recent call last):
File "/home/neel/Programming_Workspace/Not-My-Repos/tensorflow/third_party/repo.bzl", line 106
_apply_patch(ctx, ctx.attr.patch_file)
File "/home/neel/Programming_Workspace/Not-My-Repos/tensorflow/third_party/repo.bzl", line 68, in _apply_patch
fail("patch command is not found, ple...")
patch command is not found, please install it and referenced by '//third_party/eigen3:eigen3'
ERROR: Analysis of target '//tensorflow/tools/pip_package:build_pip_package' failed; build aborted: no such package '@eigen_archive//': Traceback (most recent call last):
File "/home/neel/Programming_Workspace/Not-My-Repos/tensorflow/third_party/repo.bzl", line 106
_apply_patch(ctx, ctx.attr.patch_file)
File "/home/neel/Programming_Workspace/Not-My-Repos/tensorflow/third_party/repo.bzl", line 68, in _apply_patch
fail("patch command is not found, ple...")
patch command is not found, please install it
INFO: Elapsed time: 3.142s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (42 packages loaded, 470 targets c\
onfigured)
currently loading: tensorflow/core/kernels
Fetching @eigen_archive; fetching
Fetching @double_conversion; fetching
Any other info / logs
I just cloned the latest repo from git and checked out TF r1.12 last commit. After that I passed only CPU options to “configure” and also had to install pip3. I also installed eigen3 package from my distro’s repos, but no help. I don’t know what to do, eigen does seem to be in the TF/tools/ folder but bazel doesn’t import it. Please help !!
Here’s the folder structure of “third_parties” folder:
ls ./third_party/
android libxsmm.BUILD
arm_neon_2_x86_sse.BUILD linenoise.BUILD
astor.BUILD llvm
aws lmdb.BUILD
backports_weakref.BUILD mkl
boringssl mkl_dnn
BUILD mpi
clang_toolchain mpi_collectives
codegen.BUILD nanopb.BUILD
com_google_absl.BUILD nasm
common.bzl nccl
cub.BUILD ngraph
curl.BUILD ortools
cython.BUILD pasta
double_conversion.BUILD pcre.BUILD
eigen3 png.BUILD
eigen.BUILD png_fix_rpi.patch
enum34.BUILD pprof.BUILD
examples protobuf
farmhash.BUILD py
fft2d python_runtime
flatbuffers repo.bzl
gast.BUILD six.BUILD
gif.BUILD snappy.BUILD
git sqlite.BUILD
googleapis.BUILD swig.BUILD
gpus sycl
grpc systemlibs
hadoop tensorrt
highwayhash termcolor.BUILD
hwloc tflite_mobilenet.BUILD
icu tflite_mobilenet_float.BUILD
jpeg tflite_mobilenet_quant.BUILD
jsoncpp.BUILD tflite_ovic_testdata.BUILD
kafka tflite_smartreply.BUILD
keras_applications_archive toolchains
kissfft zlib.BUILD
Heres my git branches:
git branch
master
* r1.12
git show --oneline r1.12
a6d8ffae09 (HEAD -> r1.12, tag: v1.12.0) Fix a bug in tpu.py and xla.py that while creating an identity node for control input edges under rewrite context, the parent control flow context is lost. (#23446)
diff --git a/tensorflow/contrib/compiler/xla.py b/tensorflow/contrib/compiler/xla.py
index 873b03580d..83d9d8c54a 100644
--- a/tensorflow/contrib/compiler/xla.py
+++ b/tensorflow/contrib/compiler/xla.py
@@ -179,14 +179,11 @@ class XLACompileContext(control_flow_ops.XLAControlFlowContext):
if external_control_inputs:
# Use an identity to pull control inputs as data inputs. Note that we
# ignore ops which don't have outputs. TODO(phawkins): fix that.
- with ops.control_dependencies(None):
- self.Enter()
- external_control_inputs = [
- array_ops.identity(x.outputs[0]).op
- for x in external_control_inputs
- if x.outputs
- ]
- self.Exit()
+ external_control_inputs = [
+ array_ops.identity(x.outputs[0]).op
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 18 (6 by maintainers)
Can you give an example of using wget along with bazel. It was hectic this 5 days and I’m unsure where to place the downloaded packages in the tensor flow directory. Thanks alot
I was simply recommending running wget from your terminal with the links that are failing to download. I do not think you can run “bazel with wget”, or vice versa.
Closing the issue, as the remaining problem is a network issue on user side, and we cannot do anything from our end, as all of our servers and mirrors are live and green from our end. Maybe check your firewall, or contact your network administrator or ISP.