Hi, everyone

I am facing one problem when using dgl with current reinforcement learning libraries. These libraries assume that the input graph is stored as a tensor, for example, the adjacent matrix ( bs * N * N), or edge list (bs * max_num_edge * 2).

Suppose I have the graphs stored as tensors with shape ( bs * N * N). When I need to use these graph for the downstream tasks, I have to manually turn them one by one to dgl.graph, and then use the dgl.batch to concat them. I think this way using for loop is a liitle ugly. So I am wondering that if there is an efficient way without using the for loop.

Thanks in advance!