edge ordering in undirected graph #3020
-
In an undirected graph each edge has to be specified twice; presumably the order of edges in the edge_index array is irrelevant, but the question is: is there a preferred order in terms of efficiency? For example, take the graph illustration in the "Introduction by example" doc, where: |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
There are only minor differences in terms of efficiency related to the ordering of edges, and it's not really controllable by the user. The efficiency solely depends on how many atomic operations overlap within parallel CUDA threads that point to the same target node and same feature index. As such, source/row-wise ordering or random ordering will likely perform equal, while target/col-wise ordering can bot does not have be slower. |
Beta Was this translation helpful? Give feedback.
There are only minor differences in terms of efficiency related to the ordering of edges, and it's not really controllable by the user. The efficiency solely depends on how many atomic operations overlap within parallel CUDA threads that point to the same target node and same feature index. As such, source/row-wise ordering or random ordering will likely perform equal, while target/col-wise ordering can bot does not have be slower.