TypeError: slice indices must be integers or None or have an index method
来源:互联网 发布:手机淘宝支付宝登陆 编辑:程序博客网 时间:2024/06/15 21:56
http://www.jianshu.com/p/9137efc1bd8f
这是由于numpy的版本太高,numpy 1.12.0对这个做了些调整,把numpy降级到1.11.0就行了。
参考了这篇:
sudo pip install -U numpy==1.11.0
但是我的服务器中有两个python,2.7和3.4,而系统默认pip是装在python3.4上的,这样可以看见:
输入:pip --version
显示:pip 9.0.1 from /usr/local/lib/python3.4/dist-packages (python 3.4)
所以执行以下代码,装到强制装到python2.7中:
sudo python2.7 /usr/local/bin/pip install -U numpy==1.11.0
作者:kelseyh
链接:http://www.jianshu.com/p/9137efc1bd8f
來源:简书
著作权归作者所有。商业转载请联系作者获得授权,非商业转载请注明出处。
阅读全文
0 0
- TypeError: slice indices must be integers or None or have an index method
- TypeError: slice indices must be integers or None or have an index method
- TypeError: slice indices must be integers or None or have an __index__ method
- TypeError: slice indices must be integers or None or have an __index__ method
- faster rcnn报错:TypeError: slice indices must be integers or None or have an __index__ method
- Python BeautifulSoup [解决方法] TypeError: list indices must be integers or slices, not str
- list indices must be integers or slices, not tuple
- python错误:TypeError: string indices must be integers
- matlab错误:Subscript indices must either be real positive integers or logicals.
- Subscript indices must either be real positive integers or logicals怎么解决
- matlab错误:Subscript indices must either be real positive integers or logicals.
- 处理错误TypeError: initial_value must be unicode or None, not str
- TypeError: super(type, obj): obj must be an instance or subtype of type
- TypeError: argument 1 must be string or buffer, not instance
- Python TypeError: must be string or buffer, not dict
- Tensorflow 提示list indices must be integers, not Tensor ?
- Python2.7 hmac.py TypeError: character mapping must return integer, None or unicode"
- A ref or out argument must be an assignable variable
- 基于Retrofit + RxJava的http请求的封装
- String,StringBuffer和StringBuilder
- 解决WordPress安装插件输入FTP账户信息
- (某网络公司笔试题)判断一个点是否在三角形内
- orange_17.09.18学习unity-菜单栏MenuItem
- TypeError: slice indices must be integers or None or have an index method
- three.js
- Java -- 集合Set
- 编译hadoop-eclipse插件并集成到eclipse中去
- MacOS 开发
- Druid数据连接池源码分析
- 【css3】js条件下多次触发同一个css3动画的解决方案
- 在Linux命令行下编写C语言并上传到GitHub
- NOIP2015信息传递解题报告