-
Notifications
You must be signed in to change notification settings - Fork 267
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
ValueError: Shapes (3, ?, 1) and () are incompatible #61
Comments
i have this problem before, it seems the tensorflow version is not compatable, then i change the tensorflow to 0.12, then it fixed. |
I have this problem ,and my tensorflow is 1.12.0. can you tell me your tensorflow(0.12?)Specific version ?or how to solve it?thanks! |
@legobill you can run:
|
谢谢,已经搞定了
…------------------ 原始邮件 ------------------
发件人: "Carl Hildebrandt"<[email protected]>;
发送时间: 2020年2月14日(星期五) 凌晨1:43
收件人: "yanpanlau/DDPG-Keras-Torcs"<[email protected]>;
抄送: "花花世界.个人自由自在"<[email protected]>; "Mention"<[email protected]>;
主题: Re: [yanpanlau/DDPG-Keras-Torcs] ValueError: Shapes (3, ?, 1) and () are incompatible (#61)
@legobill you can run:
pip install tensorflow==0.12
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm getting this error when I run ddpg.py:
Traceback (most recent call last):
File "ddpg.py", line 162, in
playGame()
File "ddpg.py", line 52, in playGame
actor = ActorNetwork(sess, state_dim, action_dim, BATCH_SIZE, TAU, LRA)
File "/home/marmesto/DDPG-Keras-Torcs/ActorNetwork.py", line 25, in init
self.model , self.weights, self.state = self.create_actor_network(state_size, action_size)
File "/home/marmesto/DDPG-Keras-Torcs/ActorNetwork.py", line 54, in create_actor_network
V = merge([Steering,Acceleration,Brake],mode='concat')
File "/usr/local/lib/python2.7/dist-packages/keras/engine/topology.py", line 1528, in merge
name=name)
File "/usr/local/lib/python2.7/dist-packages/keras/engine/topology.py", line 1188, in init
self.add_inbound_node(layers, node_indices, tensor_indices)
File "/usr/local/lib/python2.7/dist-packages/keras/engine/topology.py", line 572, in add_inbound_node
Node.create_node(self, inbound_layers, node_indices, tensor_indices)
File "/usr/local/lib/python2.7/dist-packages/keras/engine/topology.py", line 154, in create_node
output_tensors = to_list(outbound_layer.call(input_tensors, mask=input_masks))
File "/usr/local/lib/python2.7/dist-packages/keras/engine/topology.py", line 1275, in call
return K.concatenate(inputs, axis=self.concat_axis)
File "/usr/local/lib/python2.7/dist-packages/keras/backend/tensorflow_backend.py", line 716, in concatenate
return tf.concat(axis, [to_dense(x) for x in tensors])
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/util/dispatch.py", line 180, in wrapper
return target(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/ops/array_ops.py", line 1297, in concat
tensor_shape.scalar())
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/framework/tensor_shape.py", line 1103, in assert_is_compatible_with
raise ValueError("Shapes %s and %s are incompatible" % (self, other))
ValueError: Shapes (3, ?, 1) and () are incompatible
The text was updated successfully, but these errors were encountered: