scglue.models.data.GraphDataset.graph2triplet
- GraphDataset.graph2triplet(graph, vertices)[源代码]
Convert graph object to graph triplet
- 参数:
graph (
Graph
) – Graph objectvertices (
pandas.core.indexes.base.Index
) – Graph vertices
- 返回类型:
- 返回:
eidx – Vertex indices of edges (\(2 \times n_{edges}\))
ewt – Weight of edges (\(n_{edges}\))
esgn – Sign of edges (\(n_{edges}\))