参考stackoverflow,需要过滤掉无法识别的字符。
    如果s为str,使用s.encode(“utf-8”, “ignore”)
    如果s为bytes,使用s.decode(“utf-8”, “ignore”)