特斯拉K80内存使用TensorFlow

时间:2016-10-31 15:39:57

标签: tensorflow multi-gpu tesla

我使用特斯拉k80 GPU为TensorFlow运行了卷积神经网络的示例代码。

https://www.tensorflow.org/versions/r0.9/tutorials/deep_cnn/index.html#launching-and-training-the-model-on-multiple-gpu-cards

$ python cifar10_multi_gpu_train.py --batch_size 64 --num_gpus 2

Then I've checked a memory usage of GPU's. The result is below.

$ nvidia-smi 
Mon Oct 31 16:34:15 2016       
+------------------------------------------------------+                       
| NVIDIA-SMI 352.93     Driver Version: 352.93         |                       
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|===============================+======================+======================|
|   0  Quadro K420         Off  | 0000:01:00.0      On |                  N/A |
| 25%   45C    P0    N/A /  N/A |    264MiB /  1023MiB |      0%      Default |
+-------------------------------+----------------------+----------------------+
|   1  Tesla K80           Off  | 0000:04:00.0     Off |                    0 |
| N/A   41C    P0    66W / 149W |  11022MiB / 11519MiB |      0%      Default |
+-------------------------------+----------------------+----------------------+
|   2  Tesla K80           Off  | 0000:05:00.0     Off |                    0 |
| N/A   37C    P0    67W / 149W |    130MiB / 11519MiB |      0%      Default |
+-------------------------------+----------------------+----------------------+

+-----------------------------------------------------------------------------+
| Processes:                                                       GPU Memory |
|  GPU       PID  Type  Process name                               Usage      |
|=============================================================================|
|    0      8757    C   python                                           8MiB |
|    0     13398    G   /usr/bin/Xorg                                   92MiB |
|    0     14355    G   /usr/bin/gnome-shell                           146MiB |
|    1      8757    C   python                                       10956MiB |
|    2      8757    C   python                                          64MiB |
+-----------------------------------------------------------------------------+

“GPU 1”的内存使用量为11Gb,约为12Gb的95%。但“GPU 2”的内存使用量仅为64Mb。 你能告诉我如何在Tesla K80和TensorFlow上同时使用GPU的内存吗?

0 个答案:

没有答案