Solve the ‘UTF-8’ codec can’t decode byte 0xe9 in position 3114: invalid continuation byte error

Today, when using Python to open a file, the following error was reported:

the code is as follows:

movies = pd.read_table('../../dataset/ml-1m/movies.dat', sep='::', header=None, engine='python', encoding='utf-8').to_numpy()

Solution:
change the code to: iso-8859-1 just

movies = pd.read_table('../../dataset/ml-1m/movies.dat', sep='::', header=None, engine='python', encoding='ISO-8859-1').to_numpy()

Read More: