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

execute.py 一直报错 #152

Open
alexng88 opened this issue Feb 12, 2023 · 3 comments
Open

execute.py 一直报错 #152

alexng88 opened this issue Feb 12, 2023 · 3 comments

Comments

@alexng88
Copy link

求助! 我输入 "你好"
这句一直报错
inputs = tf.keras.preprocessing.sequence.pad_sequences([inputs],maxlen=max_length_inp, padding='post')

ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (12,) + inhomogeneous part.

有兄弟知道什么原因吗

@TimVan1596
Copy link

同样的问题

@wenChingzhou
Copy link

[inputs]改成inputs即可

@shirubei
Copy link

按照 @wenChingzhou 的提示改了以后,这个错误不再出现了,不过又碰到了另外一个错误
Tensor's shape (12, 512) is not compatible with supplied shape (1, 512), 小白,不知道该怎么弄了。

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

4 participants