14
14
# ==============================================================================
15
15
16
16
"""Tests for xception.py."""
17
+ import six
17
18
import numpy as np
18
19
import tensorflow as tf
19
20
@@ -309,7 +310,7 @@ def testClassificationShapes(self):
309
310
'xception/middle_flow/block1' : [2 , 14 , 14 , 4 ],
310
311
'xception/exit_flow/block1' : [2 , 7 , 7 , 8 ],
311
312
'xception/exit_flow/block2' : [2 , 7 , 7 , 16 ]}
312
- for endpoint , shape in endpoint_to_shape .iteritems ():
313
+ for endpoint , shape in six .iteritems (endpoint_to_shape ):
313
314
self .assertListEqual (end_points [endpoint ].get_shape ().as_list (), shape )
314
315
315
316
def testFullyConvolutionalEndpointShapes (self ):
@@ -330,7 +331,7 @@ def testFullyConvolutionalEndpointShapes(self):
330
331
'xception/middle_flow/block1' : [2 , 21 , 21 , 4 ],
331
332
'xception/exit_flow/block1' : [2 , 11 , 11 , 8 ],
332
333
'xception/exit_flow/block2' : [2 , 11 , 11 , 16 ]}
333
- for endpoint , shape in endpoint_to_shape .iteritems ():
334
+ for endpoint , shape in six .iteritems (endpoint_to_shape ):
334
335
self .assertListEqual (end_points [endpoint ].get_shape ().as_list (), shape )
335
336
336
337
def testAtrousFullyConvolutionalEndpointShapes (self ):
@@ -352,7 +353,7 @@ def testAtrousFullyConvolutionalEndpointShapes(self):
352
353
'xception/middle_flow/block1' : [2 , 41 , 41 , 4 ],
353
354
'xception/exit_flow/block1' : [2 , 41 , 41 , 8 ],
354
355
'xception/exit_flow/block2' : [2 , 41 , 41 , 16 ]}
355
- for endpoint , shape in endpoint_to_shape .iteritems ():
356
+ for endpoint , shape in six .iteritems (endpoint_to_shape ):
356
357
self .assertListEqual (end_points [endpoint ].get_shape ().as_list (), shape )
357
358
358
359
def testAtrousFullyConvolutionalValues (self ):
0 commit comments