安装tensorflow后验证时出现warning2018-06-09

使用anaconda的界面安装方式安装成功后,发现出现warn
说明tensorflow编译时没有加入这些指令集

2018-06-09 20:10:43.513215: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.1 instructions, but these are available on your machine and could speed up CPU computations.
2018-06-09 20:10:43.513239: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.2 instructions, but these are available on your machine and could speed up CPU computations.
2018-06-09 20:10:43.513247: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX instructions, but these are available on your machine and could speed up CPU computations.
2018-06-09 20:10:43.513253: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX2 instructions, but these are available on your machine and could speed up CPU computations.
2018-06-09 20:10:43.513261: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use FMA instructions, but these are available on your machine and could speed up CPU computations.
b'Hello, Tensorflow!'

禁止打印方法

import os
# 默认显示所有等级
os.environ["TF_CPP_MIN_LOG_LEVEL"]='1'
# 只显示warning和error
os.environ["TF_CPP_MIN_LOG_LEVEL"]='2'
# Error
os.environ["TF_CPP_MIN_LOG_LEVEL"]='3'

参考方法

https://blog.csdn.net/sinat_28731575/article/details/74633476

你可能感兴趣的:(安装tensorflow后验证时出现warning2018-06-09)