【发布时间】:2019-06-05 16:16:07
【问题描述】:
我正在使用 tf_upgrade_v2 将 TF1 代码升级到 TF2,我发现了这条消息:
tf.contrib.framework.nest.flatten_dict_items(dict)
AttributeError: module 'tensorflow' has no attribute 'contrib'
我应该如何更新代码?我没有找到解决方案。
【问题讨论】:
-
试试
tf.python.util.nest.flatten_dict_items。
标签: python tensorflow tensorflow2.0