zl程序教程

您现在的位置是:首页 >  其它

当前栏目

成功解决AttributeError: module 'tensorflow' has no attribute 'scalar_summary'

解决 成功 No Tensorflow module has attribute AttributeError
2023-09-14 09:04:51 时间

成功解决AttributeError: module 'tensorflow' has no attribute 'scalar_summary'

 

 

 

目录

解决问题

解决思路

解决方法


 

 

 

 

 

 

 

 

 

 

解决问题

AttributeError: module 'tensorflow' has no attribute 'scalar_summary'

 

 

 

 

 

 

 

解决思路

由于不同的TensorFlow版本之间某些函数的用法引起的错误

属性错误:模块“tensorflow”没有属性“scalar_summary”

 

 

 

 

 

 

 

解决方法

将 

tf.scalar_summary

改为

tf.summary.scalar  

哈哈,大功告成!