to_edge_index() |
Converts an adjacency matrix to an edge index representation. |
to_sparse_adjacency_matrix() |
Converts an adjacency matrix to a sparse representation as a tuple of edge index and edge features. |
to_adjacency_matrix() |
Converts an edge index representation to an adjacency matrix. |
get_src_dst_features() |
Extracts source and destination node features based on the given edge indices. |
get_unique_edge_indices() |
Computes the indices of the edges in edge_index_1 that are NOT present in edge_index_2 |
add_self_loops() |
Adds self-loops to the given graph represented by edge_index and edge_features. |
remove_self_loops() |
Removes self-loops from the given graph represented by edge_index and edge_features. |
to_undirected() |
Converts a graph given as edge_index and, optionally, edge_features to an undirected one, by adding the reverse of every edge. |
remove_duplicate_directed_edges() |
Removes the duplicate directed edges in edge_index. |
coalesce() |
Sorts edge_index by source then destination and merges duplicate edges. |
get_isolated_nodes_mask() |
Returns the indices of non-isolated nodes, or of isolated nodes. |
has_isolated_nodes() |
Function to check for isolated nodes. |
has_self_loops() |
Function to check for self loops. |