solve the problem

In import tensorflow after , When performing an operation , There was a red error !

import tensorflow as tf

import numpy as np



Reference

       Advanced Vector Extensions
<https://en.wikipedia.org/wiki/Advanced_Vector_Extensions#CPUs_with_AVX> (AVX,
also known as Sandy Bridge New Extensions)
Advanced vector expansion (AVX, Also known as the new extension of sandy Bridge ) From Intel and Intel 2008 year 3 Microprocessor's X86 Extensions of instruction set architecture , First time supported by Intel , In section 2011 Quarterly and later SoeBoE Bridge processor shipment .AMD With bulldozer processor shipping in Q3
2011.AVX New features available , New instructions and new coding scheme .AVX2 Expand most integer commands to 256 position , And introduced the fusion multiplication accumulation (FMA) operation .AVX-512 extend AVX reach 512 Bit support using a new EVEX Prefix encoding proposed by Intel 2013 year 7 month , First support for Intel and knight landing processor , stay 2016 shipment .






import os os.environ["TF_CPP_MIN_LOG_LEVEL"]='1' # This is the default display level , Show all information
os.environ["TF_CPP_MIN_LOG_LEVEL"]='2' # Show only warning and Error
os.environ["TF_CPP_MIN_LOG_LEVEL"]='3' # Show only Error
Thinking analysis


       
  Refer to comments and explanations of netizens : This means that , You downloaded TensorFlow too low 了 , No compatibility at all AVX come Compile. If you download the source code on this computer again compile, Can support AVX. In fact, your computer supports AVX Of , Just compiled TensorFlow I won't support it .

Please refer to and understand if the analysis is correct

1, First netizen

https://github.com/lakshayg/tensorflow-build Someone else compiled it


 

2, Second netizen


 

terms of settlement

Write at top line

import os
os.environ['TF_CPP_MIN_LOG_LEVEL'] = '2'