|
@@ -199,7 +199,8 @@ def _process_image(filename, coder):
|
|
|
width: integer, image width in pixels.
|
|
width: integer, image width in pixels.
|
|
|
"""
|
|
"""
|
|
|
# Read the image file.
|
|
# Read the image file.
|
|
|
- image_data = tf.gfile.FastGFile(filename, 'r').read()
|
|
|
|
|
|
|
+ with open(filename, 'r') as f:
|
|
|
|
|
+ image_data = f.read()
|
|
|
|
|
|
|
|
# Convert any PNG to JPEG's for consistency.
|
|
# Convert any PNG to JPEG's for consistency.
|
|
|
if _is_png(filename):
|
|
if _is_png(filename):
|