Reputation: 167
I have the following code:
import tensorflow as tf
print("Hello")
And the output is:
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.
Hello # This is printed about 5 seconds after the message
I had looked into the meaning of the message in this thread and in this one, but failed to make it disappear (and to run any program in less than 5 seconds). Any help would be greatly appreciated.
Upvotes: 6
Views: 17356
Reputation: 376
The message is just telling you that certain optimizations are on for you by default and if you want even more optimizations you can recompile TF to get even more performant optimizations.
By default they compile using AVX2 which isn’t the fastest AVX, but it is the most compatible.
If you don’t need to enable those (which you probably don’t) then you can just ignore the informational message knowing that you are getting some optimizations for your runs utilizing the oneDNN CPU optimizations.
Upvotes: 7