diff options
author | 2017-01-17 19:16:25 -0800 | |
---|---|---|
committer | 2017-01-17 19:25:51 -0800 | |
commit | 64ce45728c19c1058196dd64b19b2d10b7af42a3 (patch) | |
tree | ff30d9163cf0741e68236968ae0724fdda1a630a | |
parent | 1f4c2ae268dae8454163af4f94020c6578ac59ad (diff) |
Fix error in record_input_test due python2 vs 3 difference in writing strings.
Change: 144786198
-rw-r--r-- | tensorflow/python/kernel_tests/record_input_test.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tensorflow/python/kernel_tests/record_input_test.py b/tensorflow/python/kernel_tests/record_input_test.py index 4aa4059576..9b5de4fcdb 100644 --- a/tensorflow/python/kernel_tests/record_input_test.py +++ b/tensorflow/python/kernel_tests/record_input_test.py @@ -33,7 +33,7 @@ class RecordInputOpTest(test.TestCase): w = tf_record.TFRecordWriter(f) for j in range(m): - w.write("{0:0{width}}".format(i * m + j, width=10)) + w.write("{0:0{width}}".format(i * m + j, width=10).encode("utf-8")) w.close() @@ -48,7 +48,7 @@ class RecordInputOpTest(test.TestCase): batch_size=1, name="record_input").get_yield_op() - self.assertEqual(sess.run(yield_op), "0000000000") + self.assertEqual(sess.run(yield_op), b"0000000000") def testRecordInputEpochs(self): files = 100 |