Skip to content
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

[REVIEW] OPG pagerank (Py) #944

Merged
merged 11 commits into from
Jun 16, 2020
Merged

Conversation

Iroy30
Copy link
Contributor

@Iroy30 Iroy30 commented Jun 12, 2020

No description provided.

@Iroy30 Iroy30 requested review from a team as code owners June 12, 2020 03:15
@GPUtester
Copy link
Contributor

Please update the changelog in order to start CI tests.

View the gpuCI docs here.

cpp/include/graph.hpp Outdated Show resolved Hide resolved
afender added a commit to afender/cugraph that referenced this pull request Jun 12, 2020
@afender afender added the python label Jun 12, 2020
@afender afender changed the title [WIP] add opg pagerank [WIP] OPG pagerank (Py) Jun 12, 2020
@codecov-commenter
Copy link

codecov-commenter commented Jun 15, 2020

Codecov Report

Merging #944 into branch-0.15 will decrease coverage by 1.22%.
The diff coverage is 18.75%.

Impacted file tree graph

@@               Coverage Diff               @@
##           branch-0.15     #944      +/-   ##
===============================================
- Coverage        49.09%   47.86%   -1.23%     
===============================================
  Files               49       52       +3     
  Lines             1485     1548      +63     
===============================================
+ Hits               729      741      +12     
- Misses             756      807      +51     
Impacted Files Coverage Δ
python/cugraph/dask/pagerank/pagerank.py 0.00% <ø> (ø)
python/cugraph/dask/common/input_utils.py 25.30% <8.69%> (-5.85%) ⬇️
python/cugraph/dask/common/read_utils.py 11.76% <11.76%> (ø)
python/cugraph/dask/opg_pagerank/pagerank.py 30.43% <30.43%> (ø)
python/cugraph/opg/link_analysis/__init__.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 96fb44e...a804c70. Read the comment docs.

@Iroy30 Iroy30 changed the title [WIP] OPG pagerank (Py) [REVIEW] OPG pagerank (Py) Jun 16, 2020
@afender afender requested a review from kaatish June 16, 2020 17:07
Copy link
Member

@afender afender left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a few more comments, but I'm ok merging as is to unblock #947 if we address these questions in a separate PR.

from libc.stdint cimport uintptr_t
from cython.operator cimport dereference as deref

def mg_pagerank(input_df, local_data, handle, alpha=0.85, max_iter=100, tol=1.0e-5):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't support tol currently, we should throw an error if users set it (or add it later to the API).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we could add it to the final PR after #947 is merged, along with opg pagerank tests.

@@ -162,7 +162,6 @@ def pagerank(edge_list, alpha=0.85, max_iter=30):
>>> dtype=['int32', 'int32'])
>>> pr = dcg.pagerank(ddf_edge_list, alpha=0.85, max_iter=50)
"""

Copy link
Member

@afender afender Jun 16, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there some dead code from SNMG and/or things that should be in RAFT in this file?

Copy link
Contributor Author

@Iroy30 Iroy30 Jun 16, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is entirely snmg code. It simply connects to cugraph/python/cugraph/snmg/link_analysis/mg_pagerank.py which throws an exception saying it is disabled. We could update it to throw exception at python/cugraph/dask/pagerank/pagerank.py itself or just remove it completely for 0.15 release once we have OPG pagerank.

Copy link
Collaborator

@kaatish kaatish left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see some prints in the PR which look like are debugging artifacts.

There is a single commented code that can be removed.

cpp/src/link_analysis/pagerank.cu Show resolved Hide resolved

# Move to conftest
from dask_cuda import LocalCUDACluster
# cluster = LocalCUDACluster(protocol="tcp", scheduler_port=0)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this comment be removed from here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a temporary test (which is not run by CI) This is to check the validity of the PR if someone wants to test the pipeline. This is going to be replaced by a pagerank test after #947 is merged and e2e runs successfully.



def common_func(sID, data, local_data):
print("Dataframe: ", data)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are all of these debugging artifacts? Is it required to print all of this?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This going to be updated/removed in the final PR. Currently these prints exist for checking input validity as we can't verify results pagerank without Opg cuda code.

@afender afender self-requested a review June 16, 2020 19:17
@afender afender merged commit e630ffb into rapidsai:branch-0.15 Jun 16, 2020
@BradReesWork BradReesWork added this to the 0.15 milestone Jul 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants