Skip to content

Commit

Permalink
Revert "[Misc] Isort tutorials/large/L1_large_node_classification.py (d…
Browse files Browse the repository at this point in the history
…mlc#4721)" (dmlc#4741)

This reverts commit 9962b7b.
  • Loading branch information
frozenbugs authored Oct 21, 2022
1 parent 743516f commit 9b62e8d
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions tutorials/large/L1_large_node_classification.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@
# OGB already prepared the data as DGL graph.
#

import dgl
import torch
import numpy as np
from ogb.nodeproppred import DglNodePropPredDataset

dataset = DglNodePropPredDataset("ogbn-arxiv")
Expand All @@ -37,8 +40,6 @@
# simply get the graph and its node labels like this:
#

import dgl

graph, node_labels = dataset[0]
# Add reverse edges since ogbn-arxiv is unidirectional.
graph = dgl.add_reverse_edges(graph)
Expand Down Expand Up @@ -165,8 +166,6 @@
# the computation of the new features.
#

import torch

mfg_0_src = mfgs[0].srcdata[dgl.NID]
mfg_0_dst = mfgs[0].dstdata[dgl.NID]
print(mfg_0_src)
Expand All @@ -184,7 +183,6 @@

import torch.nn as nn
import torch.nn.functional as F

from dgl.nn import SAGEConv


Expand Down Expand Up @@ -289,9 +287,8 @@ def forward(self, mfgs, x):
# It also saves the model with the best validation accuracy into a file.
#

import numpy as np
import sklearn.metrics
import tqdm
import sklearn.metrics

best_accuracy = 0
best_model_path = "model.pt"
Expand Down

0 comments on commit 9b62e8d

Please sign in to comment.