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

运行程序报错 - shape不一致 #19

Open
wwwjljj opened this issue Sep 25, 2020 · 0 comments
Open

运行程序报错 - shape不一致 #19

wwwjljj opened this issue Sep 25, 2020 · 0 comments

Comments

@wwwjljj
Copy link

wwwjljj commented Sep 25, 2020

苏神好,
跑了下代码,Python使用3.6,tf使用1.15,其他环境一致,数据使用GitHub问题列表中用户链接地址,发现报错,但读了遍代码也不知道怎么修改,望苏神回复指导下:

报错文件:
kg_without_ds.py
报错位置:
image

报错信息:

InvalidArgumentError Traceback (most recent call last)
in ()
6 steps_per_epoch=len(train_D),
7 epochs=120,
----> 8 callbacks=[evaluator]
9 )
10 #else:

6 frames
/usr/local/lib/python3.6/dist-packages/tensorflow_core/python/client/session.py in call(self, *args, **kwargs)
1470 ret = tf_session.TF_SessionRunCallable(self._session._session,
1471 self._handle, args,
-> 1472 run_metadata_ptr)
1473 if run_metadata:
1474 proto_data = tf_session.TF_GetBuffer(run_metadata_ptr)

InvalidArgumentError: 2 root error(s) found.
(0) Invalid argument: Incompatible shapes: [64,226,226,8] vs. [64,226,128,1]
[[{{node attention_2/sub_1}}]]
[[loss/add/_1405]]
(1) Invalid argument: Incompatible shapes: [64,226,226,8] vs. [64,226,128,1]
[[{{node attention_2/sub_1}}]]
0 successful operations.
0 derived errors ignored.

@wwwjljj wwwjljj changed the title 运行程序报错 运行程序报错 - shape不一致 Sep 25, 2020
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

1 participant