NervanaSystems / ngraph-tf

Bridge to connect nGraph with TensorFlow
Other
53 stars 16 forks source link

build fail with --use_prebuilt_tensorflow #494

Closed cepera closed 5 years ago

cepera commented 5 years ago

when you're building the bridge with --use_prebuilt_tensorflow, the build fails like this:

...
adding 'ngraph_tensorflow_bridge-0.12.0rc4.dist-info/top_level.txt'
adding 'ngraph_tensorflow_bridge-0.12.0rc4.dist-info/RECORD'
removing build/bdist.linux-x86_64/wheel
OUTPUT WHL FILE: ngraph_tensorflow_bridge-0.12.0rc4-py2.py3-none-manylinux1_x86_64.whl
OUTPUT WHL DST: .../ngraph_20190409/build_cmake/artifacts/ngraph_tensorflow_bridge-0.12.0rc4-py2.py3-none-manylinux1_x86_64.whl
SUCCESSFULLY generated wheel: ngraph_tensorflow_bridge-0.12.0rc4-py2.py3-none-manylinux1_x86_64.whl
PWD: .../ngraph_20190409/build_cmake
cp: cannot stat '.../ngraph_20190409/build_cmake/tensorflow/tensorflow/python': No such file or directory
Traceback (most recent call last):
  File "build_ngtf.py", line 300, in <module>
    main()
  File "build_ngtf.py", line 289, in main
    os.path.join(artifacts_location, "tensorflow")
  File ".../ngraph_20190409/tools/build_utils.py", line 44, in command_executor
    raise Exception("Error running command: " + cmd)
Exception: Error running command: cp -r .../ngraph_20190409/build_cmake/tensorflow/tensorflow/python .../ngraph_20190409/build_cmake/artifacts/tensorflow

this piece of code should take --use_prebuilt_tensorflow into attention:

    # Copy the TensorFlow Python code tree to artifacts directory so that they can
    # be used for running TensorFlow Python unit tests
    command_executor([
        'cp', '-r', build_dir_abs + '/tensorflow/tensorflow/python',
        os.path.join(artifacts_location, "tensorflow")
    ])
sindhu-nervana commented 5 years ago

Hi @cepera - thanks for pointing this out. Could you please try this fix? https://github.com/NervanaSystems/ngraph-tf/commit/1243a156afbd3c437516c80ca61738c5e1809caa

We will make a release soon with this fix included.

cepera commented 5 years ago

hi @sindhu-nervana, yep, it works fine now. Thanks :)