Here is my code,
for line in open(\'u.item\'): #read each line
whenever I run this code it gives the following error:
You could resolve the problem with:
for line in open(your_file_path, 'rb'):
'rb' is reading file in binary mode. Read more here. Hope this will help!