code: def determine_encoding(self):
      while not self.eof and (
          self.raw_buffer is None or len(self.raw_buffer) < 2
      ):
          self.update_raw()
      if isinstance(self.raw_buffer, bytes):
          if self.raw_buffer.startswith(codecs.BOM_UTF16_LE):
              self.raw_decode = codecs.utf_16_le_decode
              self.encoding = "utf-16-le"
          elif self.raw_buffer.startswith(codecs.BOM_UTF16_BE):
              self.raw_decode = codecs.utf_16_be_decode
              self.encoding = "utf-16-be"
          else:
              self.raw_decode = codecs.utf_8_decode
              self.encoding = "utf-8"
      self.update(1)
  
file_path: catboost/contrib/python/PyYAML/py3/yaml/reader.py
imports: from .error import YAMLError, Mark
  import codecs, re
label_desc: Use image node_id 6 for calling the Reader obj's underlying member method code with example usage: obj.determine_encoding() without return types