You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Firstly, I want to express my appreciation for the valuable contributions made to this excellent library.
I am currently utilizing the ClusterData functionality within the library, and I am interested in applying it to weighted graphs, where the clustering of nodes is based on the weights of the edges connecting them.
Upon reviewing the source code of ClusterData, I noticed that it only utilizes the edge index of the graph. Here is the relevant snippet from the main code:
The METIS method used by ClusterData provides parameters for node weights (vweights) and edge weights (eweights), which suggests that it should be capable of handling weighted graphs.
I apologize if I have overlooked any important code or if this functionality is already available. I would greatly appreciate it if you could confirm whether weighted graph support exists in ClusterData or if it could be added in a future release.
Thank you for considering my request.
Alternatives
No response
Additional context
No response
The text was updated successfully, but these errors were encountered:
After revisiting the source code of ClusterData, I discovered an additional code snippet:
if cluster is None and torch_geometric.typing.WITH_METIS:
cluster = pyg_lib.partition.metis(
indptr.cpu(),
index.cpu(),
self.num_parts,
recursive=self.recursive,
).to(edge_index.device)
Upon further investigation into the pyg_lib.partition.metis() function, I found that it indeed supports edge weights. However, it seems that this functionality is not currently utilized in the ClusterData module.
The metis() function signature suggests that it could easily accommodate edge weights with a slight modification to the source code:
Yeah, this is well supported within pyg-lib, just not really exposed in PyG. This is not super high on my TODO, so I would appreciate some help on this one to expose this additional arguments.
馃殌 The feature, motivation and pitch
Firstly, I want to express my appreciation for the valuable contributions made to this excellent library.
I am currently utilizing the ClusterData functionality within the library, and I am interested in applying it to weighted graphs, where the clustering of nodes is based on the weights of the edges connecting them.
Upon reviewing the source code of ClusterData, I noticed that it only utilizes the edge index of the graph. Here is the relevant snippet from the main code:
The METIS method used by ClusterData provides parameters for node weights (vweights) and edge weights (eweights), which suggests that it should be capable of handling weighted graphs.
Here is the METIS function for reference:
I apologize if I have overlooked any important code or if this functionality is already available. I would greatly appreciate it if you could confirm whether weighted graph support exists in ClusterData or if it could be added in a future release.
Thank you for considering my request.
Alternatives
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: