Skip to content

Commit

Permalink
Fix GNNGraphs
Browse files Browse the repository at this point in the history
  • Loading branch information
aurorarossi committed Dec 7, 2024
1 parent 7bd58c6 commit 2e52a2c
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion GNNGraphs/docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ using DocumenterInterLinks
using GNNGraphs
using MLUtils # this is needed by setdocmeta!
import Graphs
using Graphs: induced_subgraph
using Graphs: induced_subgraph, has_edge


DocMeta.setdocmeta!(GNNGraphs, :DocTestSetup, :(using GNNGraphs, MLUtils); recursive = true)
Expand Down
4 changes: 3 additions & 1 deletion GNNGraphs/docs/src/api/heterograph.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@ Modules = [GNNGraphs]
Pages = ["gnnheterograph/query.jl"]
Private = false
```

```@docs
Graphs.has_edge(g::GNNHeteroGraph, edge_t::EType, i::Integer, j::Integer)
```
## Transform

```@autodocs
Expand Down
2 changes: 1 addition & 1 deletion GNNGraphs/src/gnnheterograph/query.jl
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ edge_index(g::GNNHeteroGraph{<:COO_T}) = only(g.graph)[2][1:2]
get_edge_weight(g::GNNHeteroGraph{<:COO_T}, edge_t::EType) = g.graph[edge_t][3]

"""
has_edge(g::GNNHeteroGraph, edge_t, i, j)
Graphs.has_edge(g::GNNHeteroGraph, edge_t::EType, i::Integer, j::Integer)
Return `true` if there is an edge of type `edge_t` from node `i` to node `j` in `g`.
Expand Down
2 changes: 1 addition & 1 deletion GNNGraphs/src/sampling.jl
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ end


"""
induced_subgraph(graph, nodes)
Graphs.induced_subgraph(graph::GNNGraph, nodes::Vector{Int})
Generates a subgraph from the original graph using the provided `nodes`.
The function includes the nodes' neighbors and creates edges between nodes that are connected in the original graph.
Expand Down

0 comments on commit 2e52a2c

Please sign in to comment.