How to understand cross_reducer in DGLHeteroGraph.multi_update_all?

In the document the cross_reducer param of dgl.DGLHeteroGraph.multi_update_all() is described as follows,

cross_reducer (str) – Cross type reducer. One of "sum" , "min" , "max" , "mean" , "stack".

I have a node type DOCUMENT connected with two type of edges, when I use stack, the node features returned are with shape [num_nodes, 2, 1, hidden_dim], the 2nd dimension means 2 types of edges, how to explain the 3rd dimension?

Hi, there was a bug associated with the stack cross reducer which was fixed in this PR. For your case, the result tensor should have a shape of [num_nodes, 2, hidden_dim]. Please install the latest nightly build of DGL or just wait a couple of days for our 0.4.3 release and you will see the fix.

Okay, thanks for your answer!