Github user jingyimei commented on a diff in the pull request: https://github.com/apache/madlib/pull/244#discussion_r177914251 --- Diff: src/ports/postgres/modules/graph/pagerank.py_in --- @@ -149,25 +186,37 @@ def pagerank(schema_madlib, vertex_table, vertex_id, edge_table, edge_args, out_cnts = unique_string(desp='out_cnts') out_cnts_cnt = unique_string(desp='cnt') v1 = unique_string(desp='v1') + personalized_nodes = unique_string(desp='personalized_nodes') if is_platform_pg(): cur_distribution = cnts_distribution = '' else: - cur_distribution = cnts_distribution = \ - "DISTRIBUTED BY ({0}{1})".format( - grouping_cols_comma, vertex_id) + cur_distribution = cnts_distribution = "DISTRIBUTED BY ({0}{1})".format( + grouping_cols_comma, vertex_id) cur_join_clause = """{edge_temp_table}.{dest} = {cur}.{vertex_id} """.format(**locals()) out_cnts_join_clause = """{out_cnts}.{vertex_id} = {edge_temp_table}.{src} """.format(**locals()) v1_join_clause = """{v1}.{vertex_id} = {edge_temp_table}.{src} """.format(**locals()) + # Get query params for Personalized Page Rank. + ppr_params = get_query_params_for_ppr(nodes_of_interest, damping_factor, --- End diff -- Is it better to check `if nodes_of_interest` before calling get_query_params_for_ppr instead of checking it in get_query_params_for_ppr?
---