tensorflow2.2.0安装_「Tensorflow 2.0」安装

7dd8cce40130cc0451bd5b17c7d3ccf7.png

anaconda安装

下载地址:

清华镜像地址

由于tensorflow2.0不支持python3.7版本,因此下载python3.6版本,anaconda和python版本对应关系如下图:

799fa7320d68d31176f243a6cf64a3d1.png

下载安装好对应版本anaconda后,通过命令安装tensorflow2.0(等正式版本上线后需要替换):

 pip install tensorflow==2.0.0-beta1

如果需要,还可以安装pandas等包:

pip install pandas etc...

jupyter notebook安装

pip install jupyter notebook

生成jupyter notebook配置文件:

jupyter notebook --generate-config

生成密码:

jupyter notebook password

拷贝~/jupyter/jupyter_notebook_config.json中的密码到jupyter_notebook_config.py:

c.NotebookApp.password = 'sha1:%s' # %s替换为自己生成的密码c.NotebookApp.ip = '*' #设置可访问的ip为任意。c.NotebookApp.open_browser = False #设置默认不打开浏览器c.NotebookApp.port = 6666 # 设置端口号c.NotebookApp.notebook_dir = '/your/file/saved/path/' # 设置默认访问的文件路径

启动jupyter notebook:

jupyter notebook # 如需后台运行,则加nohup

python虚拟环境

创建一个新的虚拟环境:

conda create -n tensorflow python=3.6

查看已有的虚拟环境:

conda env list

切换虚拟环境(tensorflow为你自己创建时的名,在此为tensorflow):

source activate tensorflow

在此打开jupyter notebook

aa0e665adff22be73eb7b52a3660f6a0.png

让我们看看有没有成功:

c336b4df568a1cfe09328bdc9997785e.png

so easy?isn’t it?


关注公众号:【算法与推荐系统】

​​​

e3964f15e72499b156a5de7eac798e79.png
  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值