code: def to_str(s):
      if six.PY2 and isinstance(s, six.text_type):
          return s.encode("utf8")
      return s
  
imports: import six
  import sys
label_desc: Use image node_id 4 for calling a global function with example usage: to_str(s) and returns: s, s