How to find which version of TensorFlow is installed in my system?

前端 未结 16 2053
轮回少年
轮回少年 2020-11-30 17:00

I need to find which version of TensorFlow I have installed. I\'m using Ubuntu 16.04 Long Term Support.

16条回答
  •  刺人心
    刺人心 (楼主)
    2020-11-30 17:49

    Almost every normal package in python assigns the variable .__version__ to the current version. So if you want to find the version of some package you can do the following

    import a
    a.__version__
    

    For tensorflow it will be

    import tensorflow as tf
    tf.version.VERSION
    

    For old versions of tensorflow (below 0.10), use tf.__version__

提交回复
热议问题