** TypeError:can can can pickle tensorflow.python.client._pywrap_tf_session.tf_operation对象**

发布于 2025-02-07 05:02:42 字数 334 浏览 4 评论 0原文

我正在使用TensorFlow-Addons API进行机器翻译项目。

我想加载模型并进行预测,而无需再次训练。

我的架构是编码器 - 使用Bahdanau注意机制解码器。

当我尝试使用 dill 模块序列化时,文件中的编码器和解码器对象,我会收到此错误:

typeerror:cockle tensorflow.pypython.client._pywrap_tf_tf_session.tf_session.tf_operation.tf_operation.tf_operation对象

如何解决这个问题?

I am using Tensorflow-addons API for a machine translation project.

I want to load my models and do predictions without train them again.

My architecture is Encoder - Decoder with Bahdanau Attention mechanism.

When I try to serialize, with dill module, the encoder and decoder objects in a file and I get this error :

TypeError: can't pickle tensorflow.python.client._pywrap_tf_session.TF_Operation objects

How can I resolve this ?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文