当前位置:网站首页>UnicodeDecodeError: ‘utf-8‘ codec can‘t decode byte 0xd0 in position 0成功解决
UnicodeDecodeError: ‘utf-8‘ codec can‘t decode byte 0xd0 in position 0成功解决
2022-07-06 09:11:00 【一曲无痕奈何】
做情感分类任务时候,读取csv文件恶心到死了,文件编码格式用notepad查看utf8,并且pycharm 也设置utf8格式,依旧一直报错,最后加了encoding="ISO-8859-1"竟然成功了,反正不理解,理论应该用utf8的,可能数据还是有问题,或者可以用记事本转一下,重新保存。
import pandas as pd
#读取数据, engine 默认是C
dataset = pd.read_csv("./data/training.1600000.processed.noemoticon.csv",encoding="ISO-8859-1",engine='python',header = None)
#查看数据表的shape
边栏推荐
- 软件测试工程师必备之软技能:结构化思维
- Several errors encountered when installing opencv
- 好博客好资料记录链接
- MySQL实战优化高手04 借着更新语句在InnoDB存储引擎中的执行流程,聊聊binlog是什么?
- 美新泽西州州长签署七项提高枪支安全的法案
- Inject common SQL statement collation
- MySQL ERROR 1040: Too many connections
- 安装OpenCV时遇到的几种错误
- Docker MySQL solves time zone problems
- MySQL real battle optimization expert 11 starts with the addition, deletion and modification of data. Review the status of buffer pool in the database
猜你喜欢

Use xtrabackup for MySQL database physical backup

MySQL storage engine

What should the redis cluster solution do? What are the plans?

Implement context manager through with

Solve the problem of remote connection to MySQL under Linux in Windows

Cmooc Internet + education
![[after reading the series] how to realize app automation without programming (automatically start Kwai APP)](/img/e1/bad9cfa70d3c533cfaddeee40b96f1.jpg)
[after reading the series] how to realize app automation without programming (automatically start Kwai APP)

C杂讲 文件 续讲

13 医疗挂号系统_【 微信登录】

The appearance is popular. Two JSON visualization tools are recommended for use with swagger. It's really fragrant
随机推荐
宝塔的安装和flask项目部署
NLP路线和资源
实现微信公众号H5消息推送的超级详细步骤
Pointer learning
美疾控中心:美国李斯特菌疫情暴发与冰激凌产品有关
vscode 常用的指令
MySQL combat optimization expert 02 in order to execute SQL statements, do you know what kind of architectural design MySQL uses?
C miscellaneous two-way circular linked list
CAPL 脚本对.ini 配置文件的高阶操作
MySQL combat optimization expert 09 production experience: how to deploy a monitoring system for a database in a production environment?
Control the operation of the test module through the panel in canoe (Advanced)
The replay block of canoe still needs to be combined with CAPL script to make it clear
MySQL ERROR 1040: Too many connections
What is the current situation of the game industry in the Internet world?
Compress decompress
[flask] crud addition and query operation of data
Contrôle de l'exécution du module d'essai par panneau dans Canoe (primaire)
A necessary soft skill for Software Test Engineers: structured thinking
竞赛vscode配置指南
Not registered via @EnableConfigurationProperties, marked(@ConfigurationProperties的使用)