-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update encoding in movielens_recommendations_transformers.py #1406
Conversation
At present the example tutorial raising the UnicodeDecodeError at the code movies=pd.read_csv() UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe9 in position 3114: invalid continuation byte Hence adding the encoding='latin-1' to the movies=pd.read_csv(...,encoding='latin-1') will get rid of this error. Hence I proposed this code change for review and approval.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR!
I was able to verify the bug and fix.
The only thing is the code formatting.
Would you please use black
to format the .py
file and also change the corresponding .ipython
and .md
file?
Done the suggested changes
Updated encoding in .ipynb file also as requested
Updated encoding in .md file as requested.
Please format the code using |
Done the changes as suggested for black format
Corrected lint errors
Removed white spaces and done required changes for black format.
All the checks passed now. May please review. |
Hi @haifeng-jin, Can you please review this PR ? Thank you! |
1 similar comment
Hi @haifeng-jin, Can you please review this PR ? Thank you! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By looking at the conflicts of the PR, the bug seems already been patched with an ISO encoding. Would you please check again while resolving the conflicts? Thanks!
Hi @SuryanarayanaY Can you please check @haifeng-jin's comments and keep us posted ? Thank you! |
Hi @SuryanarayanaY Any update on this PR? Please. Thank you! |
Closing the PR, since the tutorial is already migrated and working fine with the Keras 3 using ISO encoding here https://keras.io/examples/structured_data/movielens_recommendations_transformers/ |
At present the example tutorial raising the UnicodeDecodeError at
movies=pd.read_csv()
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe9 in position 3114: invalid continuation byte
Hence adding the
encoding='latin-1'
to themovies=pd.read_csv(...,encoding='latin-1')
will get rid of this error.Hence I proposed this code change for review and approval.
Attaching gist for reference to check the error and solution that works fine.