Open paridhimaheshwari2708 opened 2 years ago
The argument edge_type
assigns the way to calculate attention bias between every two nodes. It defaults to multi_hop
, which means using the edge in the shortest path to calculate attention bias (details could be found in Graphormer's paper Do Transformers Really Perform Badly for Graph Representation?)
If edge_type
was assigned with other values, attention bias would use other calculation methods. You can refer to graphormer/modules/graphormer_layers.py
for more details.
What does the argument edge_type (which is set to "multi_hop" default) do? How is the model different?