-
Notifications
You must be signed in to change notification settings - Fork 310
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
Remove hardcoded Pagerank dtype #1751
Conversation
Codecov Report
@@ Coverage Diff @@
## branch-21.10 #1751 +/- ##
===============================================
Coverage ? 59.75%
===============================================
Files ? 77
Lines ? 3523
Branches ? 0
===============================================
Hits ? 2105
Misses ? 1418
Partials ? 0 Continue to review full report at Codecov.
|
@@ -46,7 +46,7 @@ def pagerank(input_graph, alpha=0.85, personalization=None, max_iter=100, tol=1. | |||
|
|||
df = cudf.DataFrame() | |||
df['vertex'] = cudf.Series(np.arange(num_verts, dtype=np.int32)) |
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.
Won't this crash with 64 bit vertex IDs as well? (and see the line 37, too).
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.
I talked to @ChuckHastings and he said some of legacy algorithm only support int32 vertex ID but those will be removed as we migrate to primitive based implementations
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.
I see, but isn't this code for PageRank? @ChuckHastings Do we still have legacy implementation for PageRank? AFAIK, we're using the primitive based implementation for both SG & MG PageRank.
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.
If Pagerank is primitive based, can I just do this ?
[src, dst] = graph_primtypes_wrapper.datatype_cast([input_graph.edgelist.edgelist_df['src'], input_graph.edgelist.edgelist_df['dst']], [np.int32, np.int64])
df['vertex'] = cudf.Series(np.arange(num_verts, dtype=src.dtype))
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.
Correct. The legacy pagerank implementation was deleted a while back. @jnke2016, your cast as above should work, I believe.
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.
That looks better
@gpucibot merge |
fix hard coded pagerank dtype
closes #1737