-
I made a simple (in fact I modified a graph from PyG's example):
I tried to write my own function:
Created a networkx graph:
Homophily: This is equivalent to However, for node homophily, I get something different:
If I follow the formula and do this my hand then I also get Where am I going wrong here? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Sorry for taking so long to answer. I just ran this by myself. I think the issue is that |
Beta Was this translation helpful? Give feedback.
Sorry for taking so long to answer. I just ran this by myself. I think the issue is that
edge_index
is given as a directed graph, while you are creating an undirectednx.Graph
. Runningedge_index = to_undirected(edge_index)
fixes this.