-
Notifications
You must be signed in to change notification settings - Fork 1
Code Review and Acceralation #1
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
base: main
Are you sure you want to change the base?
Conversation
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.
Copilot reviewed 17 out of 18 changed files in this pull request and generated 1 comment.
Files not reviewed (1)
- data/ml-1m/README: Language not supported
| self.similarity_matrix = similarity.cpu().numpy() | ||
|
|
||
| # 确保对角线上是1.0(自己与自己的相似度) | ||
| np.fill_diagonal(self.similarity_matrix, 1.0) |
Copilot
AI
Apr 5, 2025
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.
The code uses 'np.fill_diagonal' but there is no corresponding import for numpy. Please add 'import numpy as np' at the top of the file.
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.
Actually we have added
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.
Copilot reviewed 17 out of 18 changed files in this pull request and generated no comments.
Files not reviewed (1)
- data/ml-1m/README: Language not supported
Comments suppressed due to low confidence (1)
src/models/user_cf.py:88
- The code uses 'np' (numpy) but numpy is not imported. Please add 'import numpy as np' at the top of the file to avoid runtime errors.
self.similarity_matrix = np.zeros((n_users, n_users))
Benedict-Y
left a comment
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.
good
| self.similarity_matrix = similarity.cpu().numpy() | ||
|
|
||
| # 确保对角线上是1.0(自己与自己的相似度) | ||
| np.fill_diagonal(self.similarity_matrix, 1.0) |
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.
Actually we have added
later will upload the final report
Update the final report
删除了一些main冗余的注释。然后改了SVD,加速运行。改了评估,加速运行,改了一些小的导入包的问题