tensorflow报错error,tf.concat Expected int32, got list containing Tensors of type '_Message' instead
参考:https://stackoverflow.com/questions/41813665/tensorflow-slim-typeerror-expected-int32-got-list-containing-tensors-of-type
我的代码是:
image_seq = tf.concat(0, image_seq)
然后就报错了:
Backend TkAgg is interactive backend. Turning interactive mode on.
Traceback (most recent call last):
File "/home/work/Pycharm/pycharm-community-2017.1.4/helpers/pydev/pydevd.py", line 1591, in <module>
globals = debugger.run(setup['file'], None, None, is_module)
File "/home/work/Pycharm/pycharm-community-2017.1.4/helpers/pydev/pydevd.py", line 1018, in run
pydev_imports.execfile(file, globals, locals) # execute the script
File "/home/tensorflow/models/research/video_prediction/grab_train_images.py", line 74, in <module>
train_image_tensor = build_image_input()
File "/home/tensorflow/models/research/video_prediction/grab_train_images.py", line 60, in build_image_input
image_seq = tf.concat(0, image_seq)
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/ops/array_ops.py", line 1061, in concat
dtype=dtypes.int32).get_shape(
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/framework/ops.py", line 611, in convert_to_tensor
as_ref=False)
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/framework/ops.py", line 676, in internal_convert_to_tensor
ret = conversion_func(value, dtype=dtype, name=name, as_ref=as_ref)
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/framework/constant_op.py", line 121, in _constant_tensor_conversion_function
return constant(v, dtype=dtype, name=name)
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/framework/constant_op.py", line 102, in constant
tensor_util.make_tensor_proto(value, dtype=dtype, shape=shape, verify_shape=verify_shape))
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/framework/tensor_util.py", line 376, in make_tensor_proto
_AssertCompatible(values, dtype)
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/framework/tensor_util.py", line 302, in _AssertCompatible
(dtype.name, repr(mismatch), type(mismatch).__name__))
TypeError: Expected int32, got list containing Tensors of type '_Message' instead. 网上说是版本问题,要改为下面的,就好了:
image_seq = tf.concat(image_seq, 0)
tensorflow报错error,tf.concat Expected int32, got list containing Tensors of type '_Message' instead的更多相关文章
- 调用tensorflow中的concat方法时Expected int32, got list containing Tensors of type '_Message' instead.
grid = tf.concat(0, [x_t_flat, y_t_flat, ones])#报错语句 grid = tf.concat( [x_t_flat, y_t_flat, ones],0) ...
- import tensorflow 报错: tf.estimator package not installed.
import tensorflow 报错: tf.estimator package not installed. 解决方案1: 安装 pip install tensorflow-estimator ...
- MySQL报错ERROR 1558 (HY000): Column count of mysql.user is wrong.
MySQL报错ERROR 1558 (HY000): Column count of mysql.user is wrong. 1.今天在使用MySQL创建数据库时出现如下报错: mysql> ...
- linux使用wkhtmltopdf报错error while loading shared libraries:
官网提示 linux需要这些动态库.depends on: zlib, fontconfig, freetype, X11 libs (libX11, libXext, libXrender) 在li ...
- 发布报错:Error ITMS-90635 - Invalid Mach-O in bundle - submitting to App store
发布报错:Error ITMS-90635 - Invalid Mach-O in bundle - submitting to App store 昨晚上传项目到AppStore,报了这个错,纳尼! ...
- 升级到macOS 10.12 mysqlb报错ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
系统升级到macOS 10.12后启动mysql后,在终端输入mysql 报错ERROR 1045 (28000): Access denied for user 'root'@'localhost' ...
- inoic start projectname sidemenu报错 - Error: Cannot find module 'lodash._baseslice'
inoic start projectname sidemenu报错 - Error: Cannot find module 'lodash._baseslice' 在公司的电脑上出现过这个错误,后来 ...
- 运行编译后的程序报错 error while loading shared libraries: lib*.so: cannot open shared object file: No such file or directory
运行编译后的程序报错 error while loading shared libraries: lib*.so: cannot open shared object file: No such f ...
- CentOS命令登录MySQL时,报错ERROR 1045 (28000):
CentOS命令登录MySQL时,报错ERROR 1045 (28000): Access denied for user root@localhost (using password: NO)错误解 ...
随机推荐
- 深入理解使用synchronized同步方法和同步代码块的区别
一.代码块和方法之间的区别 首先需要知道代码块和方法有什么区别: 构造器和方法块,构造器可以重载也就是说明在创建对象时可以按照不同的构造器来创建,那么构造器是属于对象,而代码块呢他是给所有的对象初始化 ...
- AWS Redshift typical error and potential root cause:
Full join issue: When use full join, the below join condition should not occur: 1, OR statement2, an ...
- 《Linux内核原理与分析》第六周作业
课本:第五章 系统调用的三层机制(下) 中断向量0x80和system_call中断服务程序入口的关系 0x80对应着system_call中断服务程序入口,在start_kernel函数中调用了tr ...
- Django 数据库迁移
Django 数据库迁移 DATABASES = { # Django默认配置使用sqlite3数据库 # 'default': { # 'ENGINE': 'django.db.backends.s ...
- JAVA面向对象设计中类关系
现在看以前描述有点小问题:类之间关系分为继承.泛化.依赖.关联.聚合.聚合关系几种.继承是is a关系,泛化(类实现接口)表示like a关系. 类之间的关系种类: Generalization(泛化 ...
- json转对象,奇怪的映射
偶然看见此代码,记录下,将来可能会用到. ObjectMapper objectMapper = new ObjectMapper(); if (StringUtils.isNotEmpty(vari ...
- 验证代理ip是否可用
改编自:http://www.jianshu.com/p/588241a313e7 # _*_ coding:utf-8 _*_ import urllib2 import re class Test ...
- docker4种网络最佳实战 --摘自https://www.cnblogs.com/iiiiher/p/8047114.html
考: http://hicu.be/docker-container-network-types docker默认3中网络类型 参考: https://docs.docker.com/engine/u ...
- 用TreeSet和Comparator给list集合元素去重
今天在做导入功能时,看到一个感觉很好的去重算法,特分享给大家看看: 其原理利用了以下几点: 1.TreeSet里面不会有重复的元素,所以当把一个List放进TreeSet里面后,会自动去重 2.Tre ...
- ANSI编码导致的乱码
美帝那边的一个 donet 项目,打开后发现一段string里面各种乱码.一通折腾后发现是编码格式问题.这段string所在的类文件保存格式为ANSI,而不是VS默认的UTF-8. ANSI编码电脑是 ...