tnetwork.DynGraphSN.to_tensor

DynGraphSN.to_tensor(always_all_nodes=True)[source]

Return a tensor representation

Compute the list of matrices corresponding to each graph, with nodes ordered in a same order And the dic of nodes corresponding and the list for each sn of nodes :param always_all_nodes: if True, even if a node is not active during a snapshot, it is included in the matrix :return: 3 elements:(A,B,C) A: list of numpy matrices, B: a bidictionary {node name:node order in the matrix}, C: active node at each step, as a list of list of nodes