今天在升級tensorflow 後,運行相關腳本 ,一行代碼報如下
報AttributeError: module 'tensorflow' has no attribute 'decode_raw'
網上度娘沒查到, 用tf的升級工具試了下
tf_upgrade_v2 --infile Train.py --outfile Train-new.py
可以看到 tf.decode_raw 改爲 tf.io.decode_raw
今天在升級tensorflow 後,運行相關腳本 ,一行代碼報如下
報AttributeError: module 'tensorflow' has no attribute 'decode_raw'
網上度娘沒查到, 用tf的升級工具試了下
tf_upgrade_v2 --infile Train.py --outfile Train-new.py
可以看到 tf.decode_raw 改爲 tf.io.decode_raw