前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
社区首页 >专栏 >【colab pytorch】FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a

【colab pytorch】FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a

作者头像
西西嘛呦
发布2020-08-26 10:21:11
发布2020-08-26 10:21:11
7920
举报

目前colab的tensorflow版本是1.15.0,运行时会提醒你要更新为2.x版本的,使用以下命令进行更新:

!pip uninstall tensorflow

!pip install tensorflow==2.0.0-alpha0

再运行时就会报:

FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy

这是由于tensorflow版本和numpy版本不兼容导致:

我tensorflow版本是2.0.0,numpy版本是1.17.4

使用:

!pip show numpy可以查看numpy的版本

然后执行:

!pip install numpy==1.14.0

本文参与 腾讯云自媒体同步曝光计划,分享自作者个人站点/博客。
原始发表:2020-03-12 ,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体同步曝光计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档