Skip to content

Commit

Permalink
Add networkx dep
Browse files Browse the repository at this point in the history
  • Loading branch information
mtsokol committed Jun 12, 2024
1 parent 64fc60b commit 1a22a38
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ jobs:
- name: Build and install Sparse
run: |
pip install -U setuptools wheel
python -m pip install '.[finch]' scipy
python -m pip install '.[finch]' scipy networkx
- name: Run examples
run: |
source ci/test_examples.sh
Expand Down
5 changes: 5 additions & 0 deletions examples/pagerank_example.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import importlib
import os
import time

import sparse
Expand Down Expand Up @@ -54,6 +56,9 @@ def pagerank(G, alpha=0.85, max_iter=100, tol=1e-6) -> dict:
G = nx.DiGraph(nx.path_graph(4))
ITERS = 3

os.environ[sparse._ENV_VAR_NAME] = "Finch"
importlib.reload(sparse)

# compile
pagerank(G)
print("compiled")
Expand Down

0 comments on commit 1a22a38

Please sign in to comment.