def to_unicode(text, encoding='utf8', errors='strict'):
    if isinstance(text, unicode):
        return text
    return unicode(text, encoding, errors=errors)


# Taken from gensim
Convert a string (bytestring in `encoding` or unicode), to unicode.
dataset/ETHPy150Open summanlp/textrank/summa/preprocessing/textcleaner.py/to_unicode