Setup & Software Discussions
Tensorflow GPU 1.8 with MacOS 10.13.6
 

Tensorflow GPU 1.8 with MacOS 10.13.6  

  RSS

ricc
 ricc
(@ricc)
Eminent Member
Joined: 1 year ago
 

Hi guys, after some days of trials I was finally able to properly install the GPU version of Tensorflow 1.8 and to make it work with a Nvidia 1070 boxed into an Aorus Gaming Box.
These are the required steps
(note: follow the guide at your own risk.
note2: Big part of this guide is taken from this other guide):

PREREQUISITE. Having an Nvidia GPU or EGPU (already working)

1. Install Homebrew:

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install )" brew install wget

2. Install Nvidia Web Drivers:

https://images.nvidia.com/mac/pkg/387/WebDriver-387.10.10.10.40.105.pkg

3. Install Nvidia Cuda Drivers:

https://www.nvidia.com/object/macosx-cuda-387.178-driver.html

4. Download Xcode 8.2.xip and Xcode 9.4.xip,  extract both .app, rename them to Xcode8.2.app and Xcode9.4 respectively and move then to Applications folder:

https://developer.apple.com/download/more/

You need to search for them there, it's about 4.2GB and 5.2GB. V9.4 will be needed to install OpenMP, which suggests to install that version. I don't know if latest Xcode version works instead of 9.4, if you already have latest, you could try to use that. V8.2 is essential, anyway.

5. Set Xcode8.2 as default:

sudo xcode-select -s /Applications/Xcode8.2.app

6. Install bazel:

brew install bazel

7. Install cuda 9.1.128:

https://developer.nvidia.com/cuda-91-download-archive?target_os=MacOSX&target_arch=x86_64&target_version=1013&target_type=dmglocal

8. Download and install nccl 1.3.4:

https://storage.googleapis.com/74thopen/tensorflow_osx/nccl_osx_1.3.4.tar.gz

unarchive it, open a terminal window into the extracted folder and move it into /usr/local/nccl:

sudo mkdir -p /usr/local/nccl
cd nccl_2.1.15-1+cuda9.1_x86_64
sudo mv * /usr/local/nccl
sudo mkdir -p /usr/local/include/third_party/nccl
sudo ln -s /usr/local/nccl/include/nccl.h /usr/local/include/third_party/nccl

9. Edit ~/.bash_profile:

export CUDA_HOME=/usr/local/cudaexport DYLD_LIBRARY_PATH=/usr/local/cuda/lib:/usr/local/cuda/extras/CUPTI/libexport LD_LIBRARY_PATH=$DYLD_LIBRARY_PATHexport PATH=$DYLD_LIBRARY_PATH:$PATH:/Developer/NVIDIA/CUDA-9.1/bin

10. Compile CUDA samples to test if GPU is working correctly:

cd /Developer/NVIDIA/CUDA-9.1/samples
chown -R $(whoami) *
make -C 1_Utilities/deviceQuery
./bin/x86_64/darwin/release/deviceQuery

You should get this result at the bottom of the terminal:

deviceQuery, CUDA Driver = CUDART, CUDA Driver Version = 9.1, CUDA Runtime Version = 9.1, NumDevs = 1Result = PASS

11. Register here and download cuDNN 7.0.5:

https://developer.nvidia.com/compute/machine-learning/cudnn/secure/v7.0.5/prod/9.1_20171129/cudnn-9.1-osx-x64-v7-ga

Perform:

tar -xzvf cudnn-9.1-osx-x64-v7-ga.tgz
sudo cp cuda/include/cudnn.h /usr/local/cuda/include
sudo cp cuda/lib/libcudnn* /usr/local/cuda/lib
sudo chmod a+r /usr/local/cuda/include/cudnn.h /usr/local/cuda/lib/libcudnn*

to extract and copy required files into CUDA install folder

12. Download and install Python 3.6.4:

https://www.python.org/ftp/python/3.6.4/python-3.6.4-macosx10.6.pkg

Now this is where i stopped following the guide.

13. Install Tensorflow 1.8 (other versions HERE):

pip3 install  https://storage.googleapis.com/74thopen/tensorflow_osx/tensorflow-1.8.0-cp36-cp36m-macosx_10_13_x86_64.whl 

14. Set Xcode9.4 as default:

sudo xcode-select -s /Applications/Xcode9.4.app

15. Install OpenMP:

brew install cliutils/apple/libomp


16. Finally, test installation:
Run in terminal:

python

then

>>> import tensorflow as tf
>>> tf.Session()

you should get some messages about your GPU, memory and others  (### i will insert the exact returned message ###).

17. If you get -ncclAllReduce issue:

1. Download file here:  https://github.com/tensorflow/tensorflow/blob/master/tensorflow/contrib/nccl/kernels/nccl_ops.cc
2. Execute:

gcc -c -fPIC nccl_ops.cc -o hello_world.o

3. Execute:

gcc hello_world.o -shared -o _nccl_ops.so

4. Replace generated file "nccl_ops.so" at Path:

 

tensorflow/contrib/nccl/python/ops

To find where TF is installed:

pip3 show tensorflow

you will get:

 

Name: tensorflow

Version: 1.8.0

Summary: TensorFlow helps the tensors flow

Home-page: https://www.tensorflow.org/

Author: Google Inc.

Author-email: [email protected]

License: Apache 2.0

Location: /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages

Requires: grpcio, tensorboard, wheel, astor, gast, protobuf, termcolor, numpy, six, absl-py

Required-by:


Then repeat step 12, if everything works, congratulations, you have tensorflow 1.8 with GPU support installed!

 

This topic was modified 10 months ago

2014 Macbook Pro 15" Iris Pro /w Aorus Gaming Box GTX 1070


Tony Zhang, myegpu, nullptr and 1 people liked
ReplyQuote
rickey
(@rickey)
Active Member
Joined: 2 years ago
 

Nice work. I've also built up a detailed build workflow --
https://github.com/rickeycarter/macDeepLearning

My TF 1.8 isn't working as it should.  Have you tried running some test programs to make sure it runs correctly?  For me, version 1.5 has been the only stable version. I waiting to see what the next release of TF is and determine whether or not it will support CUDA 10.

Pending: Add my system information and expected eGPU configuration to my signature to give context to my posts


ReplyQuote
ricc
 ricc
(@ricc)
Eminent Member
Joined: 1 year ago
 

What do you mean with "isn't working as it should" ?

I tried to run a Linear Regression test example, got some certificate errors, so the MNIST data won't download (didn't look so much into it). Then I tried a University code, a NLP task.

Without even optimizing it to run on GPU (i.e. increase batch size), I got a 7 times speedup (40 minutes on GPU vs 5 hours on CPU). So it definitely worked.

2014 Macbook Pro 15" Iris Pro /w Aorus Gaming Box GTX 1070


ReplyQuote
rickey
(@rickey)
Active Member
Joined: 2 years ago
 

I would have to look at the details, but some of these tests did not run properly
https://www.tensorflow.org/api_guides/python/test

I also was unable to reliably have the GPU ram allocated. It seemed to "hang" and not unload properly between runs.

Pending: Add my system information and expected eGPU configuration to my signature to give context to my posts


ReplyQuote
ricc
 ricc
(@ricc)
Eminent Member
Joined: 1 year ago
 

Ok I'll try these by tonight (12-13 hrs, sorry but can't do that earlier)

2014 Macbook Pro 15" Iris Pro /w Aorus Gaming Box GTX 1070


ReplyQuote
ricc
 ricc
(@ricc)
Eminent Member
Joined: 1 year ago
 

Sorry for being so late, it was a busy week.
I tried the test, that's what I got:

2018-10-07 00:54:40.734086: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:859] OS X does not support NUMA - returning NUMA node zero

2018-10-07 00:54:40.734379: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1356] Found device 0 with properties:

name: GeForce GTX 1070 major: 6 minor: 1 memoryClockRate(GHz): 1.721

pciBusID: 0000:c2:00.0

totalMemory: 8.00GiB freeMemory: 6.95GiB

2018-10-07 00:54:40.734399: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1435] Adding visible gpu devices: 0

2018-10-07 00:54:41.084371: I tensorflow/core/common_runtime/gpu/gpu_device.cc:923] Device interconnect StreamExecutor with strength 1 edge matrix:

2018-10-07 00:54:41.084409: I tensorflow/core/common_runtime/gpu/gpu_device.cc:929]0

2018-10-07 00:54:41.084414: I tensorflow/core/common_runtime/gpu/gpu_device.cc:942] 0: N

2018-10-07 00:54:41.084497: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1053] Created TensorFlow device (/job:localhost/replica:0/task:0/device:GPU:0 with 2457 MB memory) -> physical GPU (device: 0, name: GeForce GTX 1070, pci bus id: 0000:c2:00.0, compute capability: 6.1)

2018-10-07 00:54:41.127457: E tensorflow/core/grappler/clusters/utils.cc:127] Not found: TF GPU device with id 0 was not registered

..

----------------------------------------------------------------------
Ran 2 tests in 0.581s

 

So apparently everything is okay, except for the 

"Not found: TF GPU device with id 0 was not registered". Not sure what this is exactly

This post was modified 11 months ago

2014 Macbook Pro 15" Iris Pro /w Aorus Gaming Box GTX 1070


ReplyQuote
marquefilips
(@marquefilips)
Active Member
Joined: 8 months ago
 

I've done this and when I go into python to import tensorflow I get this: 

Python 2.7.10 (default, Oct 6 2017, 22:29:07)
[GCC 4.2.1 Compatible Apple LLVM 9.0.0 (clang-900.0.31)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named tensorflow
>>>

Any ideas?

2012 MBP15" 10.13.6, Razer X Core, NVIDIA GTX 1080, (internal Intel HD 4000/Nvidia), Nvidia 387.10.10.10.40.105, Cuda 387.130, TF 1.5 AND 2017 MBP15” 10.13.6 Razer X Core, NVidia GTX and Nvidia GTX GeForce Titan Black (when it’s not misbehaving).


ReplyQuote
ricc
 ricc
(@ricc)
Eminent Member
Joined: 1 year ago
 

It seems that you're using Python 2.7.

Try to launch python with the command "python3". Let me know!

2014 Macbook Pro 15" Iris Pro /w Aorus Gaming Box GTX 1070


ReplyQuote
Spyrtia
(@spyrtia)
New Member
Joined: 7 months ago
 

Hey I've been trying to follow your guide and upon installing Tensorflow I get stuck. 

It fails to load the native Tensorflow runtime, with the following error:

ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/_pywrap_tensorflow_internal.so, 6): Library not loaded: @rpath/libomp.dylib

  Referenced from: /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/_pywrap_tensorflow_internal.so

  Reason: image not found

Do you have any idea as to how I could fix this?

Thanks!

Edit: I managed to fix this issue by resetting the default Xcode to 8.2 and then back to 9.4 before installing openMP. It looks like it is working, but I haven't had too much time to properly test it yet.

This post was modified 7 months ago

Pending: Add my system information and expected eGPU configuration to my signature to give context to my posts


ricc liked
ReplyQuote
myegpu
(@myegpu)
New Member
Joined: 7 months ago
 

Great work!!
I followed all the steps and I think I'm "close". This is what I get when I run python and try to import tensorflow:
-----------

Python 3.6.8 |Anaconda, Inc.| (default, Dec 29 2018, 19:04:46)

[GCC 4.2.1 Compatible Clang 4.0.1 (tags/RELEASE_401/final)] on darwin

Type "help", "copyright", "credits" or "license" for more information.

>>> import tensorflow as tf

Traceback (most recent call last):

  File "<stdin>", line 1, in <module>

  File "/Users/lr/anaconda3/lib/python3.6/site-packages/tensorflow/__init__.py", line 24, in <module>

    from tensorflow.python import *

  File "/Users/lr/anaconda3/lib/python3.6/site-packages/tensorflow/python/__init__.py", line 49, in <module>

    import numpy as np

  File "/Users/lr/anaconda3/lib/python3.6/site-packages/numpy/__init__.py", line 142, in <module>

    from . import core

  File "/Users/lr/anaconda3/lib/python3.6/site-packages/numpy/core/__init__.py", line 59, in <module>

    from . import numeric

  File "/Users/lr/anaconda3/lib/python3.6/site-packages/numpy/core/numeric.py", line 3093, in <module>

    from . import fromnumeric

  File "/Users/lr/anaconda3/lib/python3.6/site-packages/numpy/core/fromnumeric.py", line 17, in <module>

    from . import _methods

  File "/Users/lr/anaconda3/lib/python3.6/site-packages/numpy/core/_methods.py", line 158, in <module>

    _NDARRAY_ARRAY_FUNCTION = mu.ndarray.__array_function__

AttributeError: type object 'numpy.ndarray' has no attribute '__array_function__'

Pending: Add my system information and expected eGPU configuration to my signature to give context to my posts


ReplyQuote
myegpu
(@myegpu)
New Member
Joined: 7 months ago
 

Thanks in advance!

And this is the deviceQuery output if it helps:
--------------

CUDA Device Query (Runtime API) version (CUDART static linking)

 

Detected 1 CUDA Capable device(s)

 

Device 0: "GeForce GTX 1080 Ti"

  CUDA Driver Version / Runtime Version          9.1 / 9.1

  CUDA Capability Major/Minor version number:    6.1

  Total amount of global memory:                 11264 MBytes (11810963456 bytes)

  (28) Multiprocessors, (128) CUDA Cores/MP:     3584 CUDA Cores

  GPU Max Clock rate:                            1633 MHz (1.63 GHz)

  Memory Clock rate:                             5505 Mhz

  Memory Bus Width:                              352-bit

  L2 Cache Size:                                 2883584 bytes

  Maximum Texture Dimension Size (x,y,z)         1D=(131072), 2D=(131072, 65536), 3D=(16384, 16384, 16384)

  Maximum Layered 1D Texture Size, (num) layers  1D=(32768), 2048 layers

  Maximum Layered 2D Texture Size, (num) layers  2D=(32768, 32768), 2048 layers

  Total amount of constant memory:               65536 bytes

  Total amount of shared memory per block:       49152 bytes

  Total number of registers available per block: 65536

  Warp size:                                     32

  Maximum number of threads per multiprocessor:  2048

  Maximum number of threads per block:           1024

  Max dimension size of a thread block (x,y,z): (1024, 1024, 64)

  Max dimension size of a grid size    (x,y,z): (2147483647, 65535, 65535)

  Maximum memory pitch:                          2147483647 bytes

  Texture alignment:                             512 bytes

  Concurrent copy and kernel execution:          Yes with 2 copy engine(s)

  Run time limit on kernels:                     Yes

  Integrated GPU sharing Host Memory:            No

  Support host page-locked memory mapping:       Yes

  Alignment requirement for Surfaces:            Yes

  Device has ECC support:                        Disabled

  Device supports Unified Addressing (UVA):      Yes

  Supports Cooperative Kernel Launch:            Yes

  Supports MultiDevice Co-op Kernel Launch:      No

  Device PCI Domain ID / Bus ID / location ID:   0 / 69 / 0

  Compute Mode:

     < Default (multiple host threads can use ::cudaSetDevice() with device simultaneously) >

 

deviceQuery, CUDA Driver = CUDART, CUDA Driver Version = 9.1, CUDA Runtime Version = 9.1, NumDevs = 1

Result = PASS

--------------------

Pending: Add my system information and expected eGPU configuration to my signature to give context to my posts


ReplyQuote
(@maximilian_m)
New Member
Joined: 8 months ago
 

The github for the ncclAllReduce issue is not availabe. Any ideas ?

Pending: Add my system information and expected eGPU configuration to my signature to give context to my posts


ReplyQuote
ricc
 ricc
(@ricc)
Eminent Member
Joined: 1 year ago
 

@maximilian_m

Hello, sorry for being so late.

I uploaded the file here:

https://github.com/antoniopioricciardi/Tensorflow-MacOS-10.13.6-eGPU

Moreover, I made some little changes to the guide, you can check it here:

https://gist.github.com/antoniopioricciardi/240921b16e32dcc67a779e11dfaade1d

This post was modified 7 months ago

2014 Macbook Pro 15" Iris Pro /w Aorus Gaming Box GTX 1070


ReplyQuote
ricc
 ricc
(@ricc)
Eminent Member
Joined: 1 year ago
 

@myegpu

By googling a bit I noticed it could be because some mix of numpy versions.
Try upgrading your pip, then uninstall numpy with 

pip uninstall numpy

Then install it with :

pip install -U numpy

2014 Macbook Pro 15" Iris Pro /w Aorus Gaming Box GTX 1070


ReplyQuote
marquefilips
(@marquefilips)
Active Member
Joined: 8 months ago
 

yeah, sorry about running 2.7, I've started again from scratch and cant' get it working, this is the error. 

Python 3.6.4 (v3.6.4:d48ecebad5, Dec 18 2017, 21:07:28)

[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin

Type "help", "copyright", "credits" or "license" for more information.

>>> import tensorflow as tf

Traceback (most recent call last):

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/pywrap_tensorflow.py", line 41, in <module>

from tensorflow.python.pywrap_tensorflow_internal import *

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/pywrap_tensorflow_internal.py", line 28, in <module>

_pywrap_tensorflow_internal = swig_import_helper()

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/pywrap_tensorflow_internal.py", line 24, in swig_import_helper

_mod = imp.load_module('_pywrap_tensorflow_internal', fp, pathname, description)

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/imp.py", line 243, in load_module

return load_dynamic(name, filename, file)

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/imp.py", line 343, in load_dynamic

return _load(spec)

ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/_pywrap_tensorflow_internal.so, 10): Library not loaded: @rpath/libcublas.8.0.dylib

Referenced from: /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/_pywrap_tensorflow_internal.so

Reason: image not found

During handling of the above exception, another exception occurred:

Traceback (most recent call last):

File "<stdin>", line 1, in <module>

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/__init__.py", line 24, in <module>

from tensorflow.python import *

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/__init__.py", line 51, in <module>

from tensorflow.python import pywrap_tensorflow

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/pywrap_tensorflow.py", line 52, in <module>

raise ImportError(msg)

ImportError: Traceback (most recent call last):

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/pywrap_tensorflow.py", line 41, in <module>

from tensorflow.python.pywrap_tensorflow_internal import *

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/pywrap_tensorflow_internal.py", line 28, in <module>

_pywrap_tensorflow_internal = swig_import_helper()

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/pywrap_tensorflow_internal.py", line 24, in swig_import_helper

_mod = imp.load_module('_pywrap_tensorflow_internal', fp, pathname, description)

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/imp.py", line 243, in load_module

return load_dynamic(name, filename, file)

File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/imp.py", line 343, in load_dynamic

return _load(spec)

ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/_pywrap_tensorflow_internal.so, 10): Library not loaded: @rpath/libcublas.8.0.dylib

Referenced from: /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/_pywrap_tensorflow_internal.so

Reason: image not found

Failed to load the native TensorFlow runtime.

See  https://www.tensorflow.org/install/install_sources#common_installation_problems 

2012 MBP15" 10.13.6, Razer X Core, NVIDIA GTX 1080, (internal Intel HD 4000/Nvidia), Nvidia 387.10.10.10.40.105, Cuda 387.130, TF 1.5 AND 2017 MBP15” 10.13.6 Razer X Core, NVidia GTX and Nvidia GTX GeForce Titan Black (when it’s not misbehaving).


ReplyQuote
marquefilips
(@marquefilips)
Active Member
Joined: 8 months ago
 

So I used the commands from this tutorial and finally got tensorflow building, ugh.  https://segmentfault.com/a/1190000015807229 - now I am going to document and script everything for the next person, this was horrible.

2012 MBP15" 10.13.6, Razer X Core, NVIDIA GTX 1080, (internal Intel HD 4000/Nvidia), Nvidia 387.10.10.10.40.105, Cuda 387.130, TF 1.5 AND 2017 MBP15” 10.13.6 Razer X Core, NVidia GTX and Nvidia GTX GeForce Titan Black (when it’s not misbehaving).


ricc liked
ReplyQuote
myegpu
(@myegpu)
New Member
Joined: 7 months ago
 

Thanks Ricc!

I finally got it to work. I had to do "ln -s" libcudart9.1, libcurand.9.1, libcufft.9.1 and libcublas.9.1.1 to their corresponding 8.0 versions. Also libcudnn.7 to its corresponding .5 version. Then I uninstalled and installed numpy. I'm just happy it works now!

I wonder why "conda install tensorflow-gpu" doesn't work. It returns PackagesNotFoundError. It'd be a lot easier if this would just work like in Windows or Ubuntu.

Pending: Add my system information and expected eGPU configuration to my signature to give context to my posts


ReplyQuote
(@tony_zhang)
New Member
Joined: 2 years ago
 

Thanks for the tutorial! I am just wondering if it's possible to use apply this on tensorflow 1.11? I am also a newbee of tensorflow. Is there any benefits from going 1.8 to 1.11?

Macbook Pro 2016 15' + Akitio Node + GTX1060 System: Mac OS 10.13.6, Win10


ReplyQuote
ricc
 ricc
(@ricc)
Eminent Member
Joined: 1 year ago
 

Nice! It would be very appreciated

2014 Macbook Pro 15" Iris Pro /w Aorus Gaming Box GTX 1070


ReplyQuote
ricc
 ricc
(@ricc)
Eminent Member
Joined: 1 year ago
 

@marquefilips Nice! It would be very appreciated.

@myegpu Probably because there's no official GPU version for tensorflow on MacOS (sadly).

@tony_zhang I don't know, it would be necessary to check the required version of CUDA and other libraries first. Then, see if there's an already compiled version of it (otherwise it needs to be compiled). After my exams - just another week  🙄 - I'll search for it and let you know! 
This post was modified 6 months ago

2014 Macbook Pro 15" Iris Pro /w Aorus Gaming Box GTX 1070


ReplyQuote
btc2lambo
(@btc2lambo)
New Member
Joined: 5 months ago
 

I keep getting the error at step 8
"-bash: cd: nccl_2.1.15-1+cuda9.1_x86_64: No such file or directory"
No sure if it is correct but I manually moved contents of "nccl_osx_1.3.4" to /usr/local/nccl

After I finished all the steps, it didn't work. 

I am also getting the error at step 10;
First of all if I just type "chown -R $(whoami) *" I get many permission denied results. so I did sudo chown -R $(whoami) *

then when I do 
make -C 1_Utilities/deviceQuery
I get the following result "make: Nothing to be done for `all' "

and then

-bash: ./bin/x86_64/darwin/release/deviceQuery: No such file or directory

Please help I have been trying this forever.
I have macbook pro 2017 10.13.6
gtx 1060 with sonnet breakaway box.

 

Pending: Add my system information and expected eGPU configuration to my signature to give context to my posts


ReplyQuote
ricc
 ricc
(@ricc)
Eminent Member
Joined: 1 year ago
 

@btc2lambo

please follow this guide: https://gist.github.com/antoniopioricciardi/240921b16e32dcc67a779e11dfaade1d

 

Step 8 - I have to look into that (whether it's better to use nccl_2.1.15 or 1.3.4 as suggested elsewhere), however what you did should be good.

Step 10 - Okay

"make: Nothing to be done for `all' " -  If I recall correctly had that message when I already compiled that file and then typed make. Try deleting compiled files.

 

Please let me know how it goes.

2014 Macbook Pro 15" Iris Pro /w Aorus Gaming Box GTX 1070


ReplyQuote
arr1vabene
(@arr1vabene)
New Member
Joined: 6 months ago
 

I could install everything and it is actually running and recognizing my egpu, but TensorFlow is not using almost anything from the GPU power, do you guys have any ideas?

I keep on getting this, but i'm not sure if it means something related to that.

What is funny is that when i ran a much deeper and complex Model while using Windows, each epoch ran in around 11 minutes.

I could check in activity monitor and the GPU actually shows a small peak at the beginning but then keeps on running with a very small load.

I could also notice that the GPU doesn't even get as hot as when i ran it on Windows

Using TensorFlow backend.

2019-06-05 01:02:46.561247: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:859] OS X does not support NUMA - returning NUMA node zero

2019-06-05 01:02:46.561408: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1356] Found device 0 with properties: 

name: GeForce GTX 1080 Ti major: 6 minor: 1 memoryClockRate(GHz): 1.6325

pciBusID: 0000:c4:00.0

totalMemory: 11.00GiB freeMemory: 9.10GiB

2019-06-05 01:02:46.561421: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1435] Adding visible gpu devices: 0

2019-06-05 01:02:46.884558: I tensorflow/core/common_runtime/gpu/gpu_device.cc:923] Device interconnect StreamExecutor with strength 1 edge matrix:

2019-06-05 01:02:46.884577: I tensorflow/core/common_runtime/gpu/gpu_device.cc:929] 0 

2019-06-05 01:02:46.884582: I tensorflow/core/common_runtime/gpu/gpu_device.cc:942] 0: N 

2019-06-05 01:02:46.884660: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1053] Created TensorFlow device (/job:localhost/replica:0/task:0/device:GPU:0 with 8801 MB memory) -> physical GPU (device: 0, name: GeForce GTX 1080 Ti, pci bus id: 0000:c4:00.0, compute capability: 6.1)

2019-06-05 01:02:47.039069: E tensorflow/core/grappler/clusters/utils.cc:127] Not found: TF GPU device with id 0 was not registered

2019-06-05 01:02:47.049827: E tensorflow/core/grappler/clusters/utils.cc:127] Not found: TF GPU device with id 0 was not registered

---------------Epoch 1---------------

Found 75750 images belonging to 101 classes.

Found 25250 images belonging to 101 classes.

0%| | 0/1184 [00:00<?, ?it/s]2019-06-05 01:02:57.059551: E tensorflow/core/grappler/clusters/utils.cc:127] Not found: TF GPU device with id 0 was not registered

2019-06-05 01:02:57.145434: E tensorflow/core/grappler/clusters/utils.cc:127] Not found: TF GPU device with id 0 was not registered

2019-06-05 01:02:57.250595: E tensorflow/core/grappler/clusters/utils.cc:127] Not found: TF GPU device with id 0 was not registered

0%|9 | 5/1184 [00:19<1:19:39, 4.05s/it]
This post was modified 3 months ago

Running a Macbook Pro 13" 2018, Razer Core X with GTX 1080TI from gigabyte


ReplyQuote
arr1vabene
(@arr1vabene)
New Member
Joined: 6 months ago
 

just to illustrate what i was talking about: the loads while running my model on tensorflow, and the load running Heaven Benchmark:
https://imgur.com/a/D6Qt1NR

Running a Macbook Pro 13" 2018, Razer Core X with GTX 1080TI from gigabyte


ReplyQuote
hypernurd
(@hypernurd)
Trusted Member
Joined: 2 years ago
 

@ricc

Good work on putting this together. I am no expert but I am trying to set-up my 2017 MBP 15" /Nvidia 1080TI/Mantiz/10.13.6 for use with Temsorflow. I have a working setup (hardware) and a fully functional GPU.

I too am having issues with some parts of your installation. Most I have overcome but I am stuck on Step 10 as @btc2lambo was (not sure if he ever got passed it);

chown -R $(whoami) * # this works if you run as sudo otherwise it errors due to lack of permissions.

make -C 1_Utilities/deviceQuery # this errors with "nothing to be done for 'all' "
./bin/x86_64/darwin/release/deviceQuery # I assume this line should form part of the above make command but when I include it I get the error " No rule to make target 'bin/x86_64/darwin/release/deviceQuey'. Stop."

TheMakefile

 in 1_Utilities/deviceQuery folder

Screen Shot 2019 07 27 at 01.07.42

 already exists and has content so I'm not entirely sure why its failing. 

What am I missing?

Thanks

 

Screen Shot 2019 07 27 at 01.07.42
This post was modified 4 weeks ago

mid-2017 15" Macbook Pro RP560 + [email protected] (Mantiz Venus) + macOS & Win10


ReplyQuote
hypernurd
(@hypernurd)
Trusted Member
Joined: 2 years ago
 

**** Update to previous post ****

Having delved a little deeper and thought about this I can now understand what is supposed to happen;
• CD to Developer/Nvidia/Cuda-9.1/Samples - takes the terminal into this working directory
• Chown - changes ownership for current user. This does work without SUDO of course as we are not changing 'system' files
• Make - call to the MakeFile in the 1_Utilities/deviceQuery folder (which exists and has what appears to be complete script content)
./bin/x86_64/darwin/release/deviceQuery - should call the executable that should have been made via the Make command. 

However, the Make command is NOT making the executable, is NOT making the new directory path and as such is NOT able to be called.

Something is up with the Makefile in the 1_Utilties/deviceQuery folder because it still states 'Nothing to be done for All" and as such its not Making the executable.

Or I have done something really wrong.

Any ideas?

This post was modified 4 weeks ago

mid-2017 15" Macbook Pro RP560 + [email protected] (Mantiz Venus) + macOS & Win10


ReplyQuote
hypernurd
(@hypernurd)
Trusted Member
Joined: 2 years ago
 

**** Update to previous post ****

I noted a MakeFile in the root Samples folder and ran a 'sudo make -C ./' - probably shouldn't have as I now appear to have installed ALL samples 🙂
The upside is I now have a 'bin' in the root of the samples folder and every sample has been built (as far as I can tell). Except, that is, 'deviceQuery' - there is no file in the 'bin/x86_64/darwin/release' folder as there is for every other sample. 
I have managed to call the deviceQueryDrv from this folder and it outputs details of the driver as one might expect. 

So, why is the deviceQuery not working or rather reporting that there is nothing to be done for All?

Hope you can help and moreover, answer whether this at all critical - which I doubt. 

Thanks.

mid-2017 15" Macbook Pro RP560 + [email protected] (Mantiz Venus) + macOS & Win10


ReplyQuote
reptilianbrain
(@reptilianbrain)
Trusted Member
Joined: 3 years ago
 

Hey guys is this still the required way? We cannot use latest Xcode / 418.168 CUDA / 387.10.10.10.40.105 GPU driver?

I have the above installed but for some reason get No Cuda-capable device error

if I follow the guide above I get Segfault..

Any advice will be greatly appreciated

This post was modified 2 weeks ago

MBP 2013 750M + Akitio [email protected]GTX1080 (Zotac Mini)


ReplyQuote