Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError: Expected int32, got <tf.Variable 'graphconvolution_1_W:0' shape=(8285, 16) dtype=float32_ref> of type 'Variable' instead. #25

Open
xjy-xing opened this issue Apr 11, 2022 · 3 comments

Comments

@xjy-xing
Copy link

sorry
run train.py and this is the error
Traceback (most recent call last):
File "/home/bfs/NEW_LAB/relational-gcn-master/rgcn/train.py", line 92, in
W_regularizer=l2(L2))([X_in] + A_in)
File "/home/bfs/miniconda3/envs/py27tf14_rgcn/lib/python2.7/site-packages/keras/engine/topology.py", line 548, in call
self.build(input_shapes)
File "build/bdist.linux-x86_64/egg/rgcn/layers/graph.py", line 69, in build
File "/home/bfs/miniconda3/envs/py27tf14_rgcn/lib/python2.7/site-packages/keras/backend/tensorflow_backend.py", line 1427, in concatenate
return tf.concat(axis, [to_dense(x) for x in tensors])
File "/home/bfs/miniconda3/envs/py27tf14_rgcn/lib/python2.7/site-packages/tensorflow/python/ops/array_ops.py", line 1096, in concat
dtype=dtypes.int32).get_shape().assert_is_compatible_with(
File "/home/bfs/miniconda3/envs/py27tf14_rgcn/lib/python2.7/site-packages/tensorflow/python/framework/ops.py", line 836, in convert_to_tensor
as_ref=False)
File "/home/bfs/miniconda3/envs/py27tf14_rgcn/lib/python2.7/site-packages/tensorflow/python/framework/ops.py", line 926, in internal_convert_to_tensor
ret = conversion_func(value, dtype=dtype, name=name, as_ref=as_ref)
File "/home/bfs/miniconda3/envs/py27tf14_rgcn/lib/python2.7/site-packages/tensorflow/python/framework/constant_op.py", line 229, in _constant_tensor_conversion_function
return constant(v, dtype=dtype, name=name)
File "/home/bfs/miniconda3/envs/py27tf14_rgcn/lib/python2.7/site-packages/tensorflow/python/framework/constant_op.py", line 208, in constant
value, dtype=dtype, shape=shape, verify_shape=verify_shape))
File "/home/bfs/miniconda3/envs/py27tf14_rgcn/lib/python2.7/site-packages/tensorflow/python/framework/tensor_util.py", line 383, in make_tensor_proto
_AssertCompatible(values, dtype)
File "/home/bfs/miniconda3/envs/py27tf14_rgcn/lib/python2.7/site-packages/tensorflow/python/framework/tensor_util.py", line 303, in _AssertCompatible
(dtype.name, repr(mismatch), type(mismatch).name))
TypeError: Expected int32, got <tf.Variable 'graphconvolution_1_W:0' shape=(8285, 16) dtype=float32_ref> of type 'Variable' instead.

Process finished with exit code 1

@jiujiuxia
Copy link

Hi! have you solved this problem?

@xjy-xing
Copy link
Author

xjy-xing commented Jun 16, 2022 via email

@Changgeww
Copy link

Hello, I have the same problem as you. May I ask how you solved it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants