Fixed a bug where file needed to be read as binary
See
@@ -145,7 +145,7 @@ def dispatch(train_files,
# h5py workaround: copy local models over to GCS if the job_dir is GCS.
def copy_file_to_gcs(job_dir, file_path):
- with file_io.FileIO(file_path, mode='r') as input_f:
+ with file_io.FileIO(file_path, mode='rb') as input_f:
with file_io.FileIO(os.path.join(job_dir, file_path), mode='w+') as output_f:
output_f.write(input_f.read())
