I have some files to read in Python, I'm using the following structure:
df = pd.read_csv (path, sep = '\ t')
And this generated the following error:
UnicodeDecodeError: 'utf-8' codec can not decode byte 0xc3 in position 9: unexpected end of data
Looking for the internet, I added a engine = 'python' (df = pd.read_csv (path, engine = 'python', sep = '\ t')) and it read normally, I thought my problems were over , but when I went to read the other files, the following error occurred:
Using encoding = 'ISO-8859-1' also solved in the first case, but in the other files it was as follows:
pandas.errors.ParserError: NULL byte detected. This byte can not be processed in Python's native csv library at the moment, so please pass in engine = 'c' instead
Visually, both files are the same, same data type, same size practically, same extension. Does anyone know why this incompatibility?