code: def decode_filename(filename):
      if isinstance(filename, bytes):
          try:
              filename_encoding = sys.getfilesystemencoding()
              if filename_encoding is None:
                  filename_encoding = sys.getdefaultencoding()
              filename = filename.decode(filename_encoding)
          except UnicodeDecodeError:
              pass
      return filename
  
imports: from __future__ import absolute_import
  import os
  import sys
  import re
  import io
  import codecs
  import shutil
  import tempfile
  from contextlib import contextmanager
label_desc: Use image node_id 14 for calling a global function with example usage: decode_filename(filename) and returns: filename