How to find out which version of tensorflow is installed in my pc?

I'm using tensorflow and have got some weired issues. I'm told it might be related to the version of tensorflow, but I don't know a proper way to find out the version I'm using.

Solution 1

You can import tensorflow and take the version from the package inside your python script, or just run one of these commands

python -c 'import tensorflow as tf; print tf.__version__'  # for Python 2
python3 -c 'import tensorflow as tf; print(tf.__version__)'  # for Python 3

* question: https://*.com/questions/38549253/how-to-find-which-version-of-tensorflow-is-installed-in-my-system

aipool discussion: https://ai-pool.com/d/how-to-find-out-which-version-of-tensorflow-is-installed-in-my-pc-