Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

can't copy tensorflow/python/pywrap_tensorflow_internal.py #9035

Closed
briancheung opened this issue Apr 7, 2017 · 15 comments
Closed

can't copy tensorflow/python/pywrap_tensorflow_internal.py #9035

briancheung opened this issue Apr 7, 2017 · 15 comments
Assignees
Labels
type:build/install Build and install issues

Comments

@briancheung
Copy link

porter@fattire:~/Projects/tensorflow$ bazel-bin/tensorflow/tools/pip_package/build_pip_package /tmp/tensorflow_pkg
Thu Apr 6 17:10:48 PDT 2017 : === Using tmpdir: /tmp/tmp.kCYPVwxjU5
~/Projects/tensorflow/bazel-bin/tensorflow/tools/pip_package/build_pip_package.runfiles ~/Projects/tensorflow
~/Projects/tensorflow
/tmp/tmp.kCYPVwxjU5 ~/Projects/tensorflow
Thu Apr 6 17:10:49 PDT 2017 : === Building wheel
error: can't copy 'tensorflow/python/pywrap_tensorflow_internal.py': doesn't exist or not a regular file

This happens after building tensorflow with bazel and running the binary build by bazel:

bazel-bin/tensorflow/tools/pip_package/build_pip_package /tmp/tensorflow_pkg

pywrap_tensorflow_internal.py doesn't exist in the source directories:

Tensorflow commit f8dce81
Bazel 0.4.5
CUDA release 8.0, V8.0.26, cuDNN 5105
GPU: NVIDIA Titan 6GB

@CharlesShang
Copy link

CharlesShang commented Apr 9, 2017

I met the same problem when installing r1.1.
bazel build --config=opt --config=cuda //tensorflow/tools/pip_package:build_pip_package was completed sucessfully.
Then I run find . -name "pywrap_tensorflow_internal.py" in the tf root dir, got nothing.
There's another relevant issue #8078

@CharlesShang
Copy link

CharlesShang commented Apr 9, 2017

A workaround:
copy ./tensorflow/python/pywrap_tensorflow.py to ./bazel-bin/tensorflow/python/pywrap_tensorflow_internal.py.
Then I got a different error /tensorflow/python/gen_resource_variable_ops.py doesn't exist or not a regular file

I think it's likely because some bazel compiling rules may be missed in r1.1.

@jart jart added the type:build/install Build and install issues label Apr 12, 2017
@jart jart self-assigned this Apr 14, 2017
@lzamparo
Copy link

+1, experiencing the same issue

Tensorflow commit d48ef8f
Bazel 0.4.5
CUDA release 8.0, V8.0.26, cuDNN 5105
GPU: NVIDIA GTX 1080

The file in question clearly exists:

[zamparol@server tensorflow]$ ls -lh tensorflow/python/pywrap_tensorflow.py
-rw-r--r-- 1 zamparol cllab 2.5K Apr 25 15:47 tensorflow/python/pywrap_tensorflow.py

@lzamparo
Copy link

lzamparo commented Apr 26, 2017

FWIW, I resolved my issue (sol'n provided towards the end of #1334), I'm not sure what the problem is but I was able to build a wheel by doing the following from the root of the repo:

git submodule update --init
bazel clean --expunge
bazel build -c opt --config=cuda --verbose_failures //tensorflow/tools/pip_package:build_pip_package
bazel-bin/tensorflow/tools/pip_package/build_pip_package ~/utils/tensorflow_pkg

Maybe if one of the bazel build steps fails, you need to do bazel clean --expunge, and try again?

@jart
Copy link
Contributor

jart commented Apr 26, 2017

Does that solve your issue @CharlesShang?

@CharlesShang
Copy link

Unfortunately, It failed again.
The same error mssg was prompted out.
I'm on commit 1ec6ed5.

@rogerxujiang
Copy link

I had a similar issue and was able to fix it by removing the VERBS support from the configure. This is what (I guess) happened: bazel build with the VERBS support actually failed, but I didn't notice it and it still created the file of 'bazel-bin/tensorflow/tools/pip_package/build_pip_package'. And this file gives me the error.

@CharlesShang
Copy link

@jiangxu87 Could you please give a more detailed howto?

@nishalpereira
Copy link

@CharlesShang

Was your error solved?
I have the same error. please help

@CharlesShang
Copy link

No.
@nishalpereira, I've installed the pre-built binary instead.

@nishalpereira
Copy link

@CharlesShang
Thanks for your reply.
Can you tell me how to install the pre-built binary.

@CharlesShang
Copy link

This problem is random.
On another machine (same OS, same cuda version, but different GPU), tf can be built successfully. So I just copy the built file to my machine, install it..

@tensorflowbutler
Copy link
Member

It has been 14 days with no activity and this issue has an assignee.Please update the label and/or status accordingly.

@tensorflowbutler
Copy link
Member

Nagging Assignee: It has been 14 days with no activity and this issue has an assignee. Please update the label and/or status accordingly.

@jart
Copy link
Contributor

jart commented Jan 16, 2018

Closing due to inactivity. If it's still an issue let us know and I'll reopen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:build/install Build and install issues
Projects
None yet
Development

No branches or pull requests

7 participants