瀏覽代碼

Python3 dict.values() does not return a list

Add a list wrapper will make it run properly in Python3 as well as Python2.
Aaron Hu 9 年之前
父節點
當前提交
0594661a20
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      slim/eval_image_classifier.py

+ 1 - 1
slim/eval_image_classifier.py

@@ -183,7 +183,7 @@ def main(_):
         checkpoint_path=checkpoint_path,
         checkpoint_path=checkpoint_path,
         logdir=FLAGS.eval_dir,
         logdir=FLAGS.eval_dir,
         num_evals=num_batches,
         num_evals=num_batches,
-        eval_op=names_to_updates.values(),
+        eval_op=list(names_to_updates.values()),
         variables_to_restore=variables_to_restore)
         variables_to_restore=variables_to_restore)