Skip to content

Commit

Permalink
improved evaluation docs
Browse files Browse the repository at this point in the history
  • Loading branch information
maniospas committed Jun 12, 2024
1 parent 23b4b6a commit 611a445
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions examples/playground/multigroup.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import pygrank as pg

_, graph, communities = next(pg.load_datasets_multiple_communities(["dblp"]))
algorithm = pg.PageRank(alpha=0.9, assume_immutability=True) # cache graph preprocessing
algorithm = pg.PageRank(
alpha=0.9, assume_immutability=True
) # cache graph preprocessing

comm_scores = {name: algorithm(graph, members) for name, members in communities.items()}

import tqdm # install this to be able to set it as a progress bar argument below

measure = pg.LinkAssessment(graph, progress=tqdm.tqdm)
print(measure(comm_scores))

0 comments on commit 611a445

Please sign in to comment.