Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Jan 14, 2025
1 parent 9747aa2 commit 5a32171
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion torch_geometric/loader/rag_loader.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,13 @@ def query(self, query: Any) -> Data:

data = self.feature_store.load_subgraph(sample=subgraph_sample,
**self.loader_kwargs)
data.node_idx = torch.tensor(list(dict.fromkeys(list(self.graph_store.edge_index[:, data.edge_idx].t().reshape(-1)))))
data.node_idx = torch.tensor(
list(
dict.fromkeys(
list(
self.graph_store.edge_index[:,
data.edge_idx].t().reshape(
-1)))))
data.x = self.feature_store.x[data.node_idx]
if self.local_filter:
data = self.local_filter(data, query)
Expand Down

0 comments on commit 5a32171

Please sign in to comment.