Ahmet Onur Solmaz
Ahmet Onur Solmaz

Reputation: 19

ParseError: Error tokenizing data. C error: Buffer overflow caught - possible malformed input file. (read_csv)

I cannot use read_csv method of pandas properly on kaggle. Error that I get is:

ParseError: Error tokenizing data. C error: Buffer overflow caught - possible malformed input file.

I found some suggestions about this (read_excel, read by column). However, they do not help me to solve this error.

Upvotes: 1

Views: 5363

Answers (1)

alemol
alemol

Reputation: 8642

I solved the same problem just by adding engine='python':

df = pd.read_csv(fname, sep='\t',
                 engine='python',
                 header=None)

Upvotes: 1

Related Questions