Reputation: 29
I've been trying to compile tensorflow 1.1 inception with bazel 0.4.2 on windows 10 using CUDA 8.0.
I haven't been able to find a corresponding error online.
C:\Users\me\Anaconda3\envs\tensorflow_gpu\tensorflow>bazel build --config=opt tensorflow/examples/image_retraining:retrain
ERROR: C:/users/me/appdata/local/temp/_bazel_simon/qco1pmlq/external/local_config_cuda/cuda/BUILD:172:12: in outs attribute of genrule rule @local_config_cuda//cuda:cuda-include: Genrules without outputs don't make sense.
After digging into the Build file specified in the error message I have these genrules which are missing inputs:
genrule(
name = "cuda-include",
outs = [
],
cmd = """
""",
)
genrule(
name = "cuda-nvvm",
outs = [
],
cmd = """
""",
)
genrule(
name = "cuda-extras",
outs = [
],
cmd = """
""",
)
I am assuming these should have been generated? I do have an example of other rules that follow that format but unsure which files and if that is the correct way to go. Any help would be greatly appreciated.
Upvotes: 0
Views: 1582
Reputation: 363
Tensorflow GPU Build with Bazel on Windows is not very stable. Currently it's broken from both sides.
This change was just sent to fix problems in Bazel.
And this PR will make Cuda configuration work on Windows again.
You can first build Bazel from HEAD. And after the PR is merged, use your custom Bazel to build TensorFlow from HEAD.
The correct command on Windows would be:
bazel build -c opt --config=win-cuda --cpu=x64_windows_msvc --host_cpu=x64_windows_msvc --copt=-w --host_copt=-w tensorflow/tools/pip_package:build_pip_package
FYI, there is a script for building TensorFlow on Windows: https://github.com/tensorflow/tensorflow/blob/master/tensorflow/tools/ci_build/windows/gpu/pip/build_tf_windows.sh
Upvotes: 2