tensorflow 使用 gpu

tf gpu tutorial

运行 Tensorflow 终端输出:OMP: Info #172: KMP_AFFINITY: OS proc 126 maps to socket 1 core 30 thread 1

结论:它只是正常输出一些 OpenMP debug messages,可以通过下面命令抑制输出:

1
2
import os
os.environ["KMP_WARNINGS"] = "FALSE"

python - Weird output when using TensorFlow backend on Keras (OMP: Info #xx KMP_AFFINITY) - Stack Overflow