Unverified Commit cbfc8085 authored by Hongzhi (Steve), Chen's avatar Hongzhi (Steve), Chen Committed by GitHub
Browse files

[Misc] Always use subgraph instead of sub_graph. (#6213)

parent b8e93575
......@@ -88,7 +88,7 @@ class NeighborSampler(SubgraphSampler):
self.prob_name = prob_name
self.graph = graph
def _sample_sub_graphs(self, seeds):
def _sample_subgraphs(self, seeds):
subgraphs = []
num_layers = len(self.fanouts)
for hop in range(num_layers):
......
......@@ -40,9 +40,7 @@ class SubgraphSampler(Mapper):
seeds = data.seed_node
else:
raise TypeError(f"Unsupported type of data {data}.")
data.input_nodes, data.sampled_subgraphs = self._sample_sub_graphs(
seeds
)
data.input_nodes, data.sampled_subgraphs = self._sample_subgraphs(seeds)
return data
def _link_prediction_preprocess(self, data):
......@@ -105,5 +103,5 @@ class SubgraphSampler(Mapper):
compacted_negative_tail if has_neg_dst else None,
)
def _sample_sub_graphs(self, seeds):
def _sample_subgraphs(self, seeds):
raise NotImplementedError
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment