Skip to content

build from source code then reinstall tensorflow #775

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

Closed
SmileTM opened this issue Dec 17, 2019 · 2 comments
Closed

build from source code then reinstall tensorflow #775

SmileTM opened this issue Dec 17, 2019 · 2 comments

Comments

@SmileTM
Copy link

SmileTM commented Dec 17, 2019

cuda 9.0
cudnn 7

I had installed tensorflow2.0-gpu that was bazeled from source code.
And tf.test.is_gpu_available() is true

Then I had changed configure.sh

if [[ "$TF_NEED_CUDA" == "1" ]]; then
    write_action_env_to_bazelrc "TF_NEED_CUDA" ${TF_NEED_CUDA}
    write_action_env_to_bazelrc "CUDNN_INSTALL_PATH" "${CUDNN_INSTALL_PATH:=/disk1/lx/cuda/lib64}"
    write_action_env_to_bazelrc "TF_CUDA_VERSION" "9.0"
    write_action_env_to_bazelrc "TF_CUDNN_VERSION" "7"
    write_action_env_to_bazelrc "CUDA_TOOLKIT_PATH" "${CUDA_HOME:=/disk1/lx/cuda}"

Then I run ./configure.sh , it will reinstall tf-nightly.
how to change this dependency ?

@seanpmorgan
Copy link
Member

Hi @SmileTM, we're working on our build to be more flexible for custom configurations. See #770. I suspect this will be completed before the new year.

If you would like to see if you can get it to work prior to those changes, you'll want to change the requirement in build_deps: https://github.com/tensorflow/addons/blob/master/build_deps/requirements.txt so that it requires tf2-gpu instead of the nightly. That way if it exists there will be no installation from ./configure.sh. No promises that the CUDA build won't fail for CUDA 9.0, but in the near future it should work out of the box

@SmileTM
Copy link
Author

SmileTM commented Dec 19, 2019

Hi @SmileTM, we're working on our build to be more flexible for custom configurations. See #770. I suspect this will be completed before the new year.

If you would like to see if you can get it to work prior to those changes, you'll want to change the requirement in build_deps: https://github.com/tensorflow/addons/blob/master/build_deps/requirements.txt so that it requires tf2-gpu instead of the nightly. That way if it exists there will be no installation from ./configure.sh. No promises that the CUDA build won't fail for CUDA 9.0, but in the near future it should work out of the box

have a good news to you.
I have successed to bazel and install the addons in cuda 9.0 and cudnn 7.
You can refer
http://s-tm.cn/2019/12/19/tensorflow-addons/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants