我有一个熊猫的数据框,其页面字段包含如下条目:Francisco_el_matemático_(serie_de_televisión_de_2017)_es.wikipedia.org_all-access_spider
我使用.values
将其转换为numpy数组,但它似乎很Francisco_el_matemxc3xa1tico_(serie_de_televisixc3xb3n_de_2017)_es.wikipedia.org_all-access_spider
无论如何,保留字符串的原始格式吗?
这实际上是编码问题。
在 python 脚本的开头添加此行
# -*- coding: utf-8 -*-