NameError: name 'XXX' is not defined

出现问题可能是在在上面函数中定义了learning_rate,而下面是是顶格。python和C/C++不同的地方是python的缩行代表了变量作用的范围。这也是《TensorFlow实战Google深度学习框架》这本书中的一个小错误。

猜你喜欢

转载自blog.csdn.net/weixin_36670529/article/details/88120979