2017-01-05 172 views
1

我嘗試從源代碼安裝Tensorflow。Tensorflow安裝失敗。 TensorContractionThreadPool.h:沒有這樣的文件或目錄

./configure 
bazel build --copt=-march=native --copt=-mavx --copt=-mavx2 --copt=-mfma --copt=-mfpmath=both -c opt --config=cuda //tensorflow/tools/pip_package:build_pip_package 

但是當我做「巴澤勒建設......」它提升一個像這樣的異常..

ERROR: /home/anderson/Downloads/tensorflow/tensorflow/core/kernels/BUILD:300:1: C++ compilation of rule '//tensorflow/core/kernels:reader_base' failed: crosstool_wrapper_driver_is_not_gcc failed: error executing command external/local_config_cuda/crosstool/clang/bin/crosstool_wrapper_driver_is_not_gcc -U_FORTIFY_SOURCE '-D_FORTIFY_SOURCE=1' -fstack-protector -fPIE -Wall -Wunused-but-set-parameter ... (remaining 115 argument(s) skipped): com.google.devtools.build.lib.shell.BadExitStatusException: Process exited with status 1. 
In file included from ./tensorflow/core/framework/numeric_types.h:25:0, 
      from ./tensorflow/core/framework/allocator.h:23, 
      from ./tensorflow/core/framework/op_kernel.h:22, 
      from ./tensorflow/core/framework/queue_interface.h:22, 
      from ./tensorflow/core/kernels/reader_base.h:21, 
      from tensorflow/core/kernels/reader_base.cc:16: 
./third_party/eigen3/unsupported/Eigen/CXX11/FixedPoint:42:52: fatal error: src/Tensor/TensorContractionThreadPool.h: No such file or directory 
compilation terminated. 
Target //tensorflow/tools/pip_package:build_pip_package failed to build 
Use --verbose_failures to see the command lines of failed build steps. 

說得簡單,它說「SRC /張量/ TensorContractionThreadPool.h:無這樣的文件或目錄「

我能做些什麼來解決這個問題?

+0

是的,已知的問題。在https://github.com/tensorflow/tensorflow/issues/6558 –

+0

@YaroslavBulatov的評論中有一個解決方法謝謝。但沒有任何建議不能解決問題.... – Anderson

回答

0

我是這樣做的:

  1. 克隆https://bitbucket.org/eigen/eigen
  2. 複製Tensor文件夾放到tensorflow:cp -r eigen/unsupported/Eigen/CXX11/src/Tensor tensorflow/third_party/eigen3/unsupported/Eigen/CXX11/src/
  3. 編輯tensorflow/third_party/eigen3/BUILD改變:

    glob(["unsupported/Eigen/CXX11/src/FixedPoint/*.h"]) + [ 
    

    到:

    hdrs = glob(["unsupported/Eigen/CXX11/src/FixedPoint/*.h"]) + 
         glob(["unsupported/Eigen/CXX11/src/Tensor/*.h"]) + [ 
    

    你也許還可以使用.../src/*/*.h

  4. 運行bazel build正常
0

@naktinis是正確的!從到位桶 但汞克隆回購是怕麻煩,ü應該安裝水銀首先:在HEAD

# Debian/Ubuntu 
$ apt-get install mercurial 

# Fedora 
$ yum install mercurial 

# Gentoo 
$ emerge mercurial 

# Mac OS (homebrew) 
$ brew install mercurial 

# FreeBSD 
$ cd /usr/ports/devel/mercurial 
$ make install 

# Solaris 11 Express 
$ pkg install SUNWmercurial 
相關問題