tensorflow 中遇到的問題總結

tensorflow 中遇到的問題總結

 

1.TFRecordReader "OutOfRangeError (see above for traceback): RandomShuffleQueue '_1_shuffle_batch/random_shuffle_queue' is closed and has insufficient elements (requested 1, current size 0)" 

輸入數據維數不對,一般是參數維度不一致造成的,容易出錯的地方:

(1)製作、解碼tf_record時候,圖片size是、通道數、編碼是否一致,比如tf.decode_raw(features['image_raw'],tf.uint8),製作tf_record的時候圖片也該是uint8(容易與float32弄混)

(2)tf.local_variables_initializer()、tf.global_variables_initializer()簡單點兩個都寫

(3)tf.train.shuffle_batch函數問題,嘗試增加num_threads數量,這種情況一般是(requested 128, current size 36)之類的。

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章