Skip to content

Commit

Permalink
placeholder
Browse files Browse the repository at this point in the history
  • Loading branch information
RobRossmiller-TG committed Sep 6, 2024
1 parent 8aa56b0 commit 3b74f2a
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions tests/test/baseline/algos/pagerank.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
import networkx as nx
import pandas as pd
from pyTigerGraph.datasets import Datasets

from .base import Baseline
from .common import create_baseline


def run_pagerank(g: nx.Graph, metric):
res = metric(g)

out = []
for k, v in res.items():
out.append({"Vertex_ID": k, "score": v})

out = [{"@@top_scores_heap": out}]
return out


class PagerankBaseline(Baseline):
def __init__(self, data_path_root, baseline_path_root):
self.data_path_root = data_path_root
self.baseline_path_root = baseline_path_root

def run(self):
return

0 comments on commit 3b74f2a

Please sign in to comment.