Tensorflow中的StreamExecutor设备(0):主机,默认版本

4

我正在尝试在本地计算机上执行一个TensorFlow脚本,但出现了以下警告。如果有人能够指出这个警告的常见原因,那将非常有帮助。

2020-10-26 14:04:34.690753: I tensorflow/core/platform/cpu_feature_guard.cc:142] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN)to use the following CPU instructions in performance-critical operations:  AVX2 FMA
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2020-10-26 14:04:34.707717: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x7fadab4339f0 initialized for platform Host (this does not guarantee that XLA will be used). Devices:
2020-10-26 14:04:34.707751: I tensorflow/compiler/xla/service/service.cc:176]   StreamExecutor device (0): Host, Default Version

我尝试跟踪我的代码,发现出错的代码行是:

model = load_model(MODEL_PATH)

我使用以下方式导入load_model

from keras.models import load_model
1个回答

0
上述警告的主要原因是 Tensorflow 库未针对您特定的架构进行优化,因为 Tensorflow 最初是在不同架构的机器上编译的。
您可以忽略此警告,但您将无法从库中获得最大性能。
要解决此警告并获得最大性能,您需要在您的机器上构建 Tensorflow
您可以按照 this 文档来构建适用于Linux和macOS的Tensorflow,对于Windows,您可以按照 this 文档操作。

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接