如何检查安装了哪个版本的Keras? [英] How to check which version of Keras is installed?

查看:92
本文介绍了如何检查安装了哪个版本的Keras?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

问题与标题中的问题相同.

Question is the same as the title says.

我不想打开Python,而是使用MacOS或Ubuntu.

I prefer not to open Python and I use either MacOS or Ubuntu.

推荐答案

Python库作者将版本号放在<module>.__version__中.您可以通过在命令行上运行它来打印它:

Python library authors put the version number in <module>.__version__. You can print it by running this on the command line:

python -c 'import keras; print(keras.__version__)'

如果是Windows终端,请在代码段中用双引号将其括起来,如下所示

If it's Windows terminal, enclose snippet with double-quotes like below

python -c "import keras; print(keras.__version__)"

这篇关于如何检查安装了哪个版本的Keras?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆