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

Fix/normalized hypergraph laplacian #648

Merged
merged 28 commits into from
Jan 30, 2025
Merged
Changes from 1 commit
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
41cc8d1
fix: rewrite `normalized_hypergraph_laplacian`
kaiser-dan Jan 24, 2025
a74ea93
test: add unit tests for updated laplacian
kaiser-dan Jan 24, 2025
5a924a3
doc: update `normalized_hypergraph_laplacian` doc
kaiser-dan Jan 24, 2025
c85c72b
test: added issue #657 m.w.e. as test
kaiser-dan Jan 25, 2025
4881074
fix(test): fix typo in unit test
kaiser-dan Jan 26, 2025
5de2a16
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 28, 2025
938e51b
test: add sqrt(d) eigenvector, true_L tests
kaiser-dan Jan 28, 2025
6717ec7
Merge branch 'fix/normalized_hypergraph_laplacian' of github.com:kais…
kaiser-dan Jan 28, 2025
60f3802
feat: update weighted argument for laplacian
kaiser-dan Jan 28, 2025
573eaad
doc: update normalized_hypergraph_laplacian args
kaiser-dan Jan 28, 2025
726340b
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 29, 2025
e1cf910
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 29, 2025
91b7522
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 29, 2025
1fc3593
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 29, 2025
5689658
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 29, 2025
6f128f4
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 29, 2025
292017c
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 29, 2025
10a6738
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 29, 2025
fd0197b
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 29, 2025
be0e6c9
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 28, 2025
251e21d
feat: update weighted argument for laplacian
kaiser-dan Jan 28, 2025
1b0fa8e
doc: update normalized_hypergraph_laplacian args
kaiser-dan Jan 28, 2025
60762ea
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 29, 2025
059d05c
test: separated #647 m.w.e. into new test
kaiser-dan Jan 29, 2025
88cdd4c
feat: update scipy sparse array to modern use
kaiser-dan Jan 29, 2025
da60d74
Merge branch 'fix/normalized_hypergraph_laplacian' of github.com:kais…
kaiser-dan Jan 29, 2025
1d5598b
chore: update diags_array scipy use in 'laplacian'
kaiser-dan Jan 29, 2025
327e6cd
Update xgi/linalg/laplacian_matrix.py
kaiser-dan Jan 30, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions xgi/linalg/laplacian_matrix.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@
from ..exception import XGIError
from .hypergraph_matrix import (
adjacency_matrix,
clique_motif_matrix,
degree_matrix,
incidence_matrix,
)
Expand Down Expand Up @@ -107,7 +106,7 @@ def laplacian(H, order=1, sparse=False, rescale_per_node=False, index=False):
return (L, {}) if index else L

if sparse:
K = csr_array(diags(degree_matrix(H, order=order)))
K = csr_array(diags_array(degree_matrix(H, order=order)))
kaiser-dan marked this conversation as resolved.
Show resolved Hide resolved
else:
K = np.diag(degree_matrix(H, order=order))

Expand Down