1. 程式人生 > >安裝tensorflow遇到:Your CPU supports instructions that this TensorFlow binary was not compiled to use

安裝tensorflow遇到:Your CPU supports instructions that this TensorFlow binary was not compiled to use

pil 屏蔽警告 block 問題 方法 imp 計算 body fma

為了提升CPU計算速度的。若你有支持cuda的GPU,則可以忽略這個問題,因為安裝SSE4.1, SSE4.2, AVX, AVX2, FMA, 僅僅提升CPU的運算速度(大概有3倍)。

解決方法:

  1. 忽視警告,並屏蔽警告

開頭輸入如下:

import os

os.environ[‘TF_CPP_MIN_LOG_LEVEL‘] = ‘2‘

2.進 tensorflow 官網,從源碼安裝。

安裝tensorflow遇到:Your CPU supports instructions that this TensorFlow binary was not compiled to use