Skip to content

Commit f1faa28

Browse files
update add_self_loops docstring
1 parent 5250c4d commit f1faa28

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

src/GNNGraphs/transform.jl

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -41,17 +41,17 @@ end
4141
"""
4242
add_self_loops(g::GNNHeteroGraph, edge_t::EType)
4343
44-
If the source node type is the same as destination node type in `edge_t`,
45-
return a graph with the same features as `g` but also adding self-loops
46-
of the specified type, `edge_t`. Otherwise it returns `g` unchanged.
44+
If the source node type is the same as the destination node type in `edge_t`,
45+
return a graph with the same features as `g` but also add self-loops
46+
of the specified type, `edge_t`. Otherwise, it returns `g` unchanged.
4747
48-
Nodes with already existing self-loops of type edge_t will obtain
49-
a second self-loop of type edge_t.
48+
Nodes with already existing self-loops of type `edge_t` will obtain
49+
a second set of self-loops of the same type.
5050
51-
If the graphs has edge weights for edges of type edge_t, the new edges will have weight 1.
51+
If the graph has edge weights for edges of type `edge_t`, the new edges will have weight 1.
5252
53-
If no edges of type edge_t exist, or all existing edges have no weight,
54-
then all new self loops will have no weight.
53+
If no edges of type `edge_t` exist, or all existing edges have no weight,
54+
then all new self-loops will have no weight.
5555
"""
5656
function add_self_loops(g::GNNHeteroGraph{Tuple{T, T, V}}, edge_t::EType) where {T <: AbstractVector{<:Integer}, V}
5757
function get_edge_weight_nullable(g::GNNHeteroGraph{<:COO_T}, edge_t::EType)

0 commit comments

Comments
 (0)