code: def _read_utf_8_file(filename):
      if sys.version_info.major == 2:  ## Python 2 specific
          with open(filename, "rb") as f:
              return unicode(f.read(), "utf-8")
      else:
          with open(filename, encoding="utf-8") as f:
              return f.read()
  
file_path: TensorLayer/tests/pending/test_yapf_format.py
imports: import sys
  import unittest
  from yapf.yapflib.yapf_api import FormatCode
  from tests.utils import CustomTestCase, list_all_py_files
label_desc: Use image node_id 1 for calling a global function with example usage: _read_utf_8_file(filename) and returns: unicode, f