Line too long (114 > 79 characters):
20 def __init__(self, version=None, root_dir='data', download=False, split_scheme='official', random_split=False,Line too long (138 > 79 characters):
31 self._y_type = 'float' # although the task is binary classification, the prediction target contains nan value, thus we need floatLine too long (85 > 79 characters):
40 metadata_file_path = os.path.join(self.ogb_dataset.raw_dir, 'UPFD_group.npy')Line too long (106 > 79 characters):
43 'https://www.dropbox.com/s/bs5u83x2vjf7t0f/UPFD_group.zip?dl=1', self.ogb_dataset.raw_dir)Line too long (103 > 79 characters):
46 self._metadata_array_wo_y = torch.from_numpy(np.load(metadata_file_path)).reshape(-1, 1).long()Line too long (94 > 79 characters):
48 torch.unsqueeze(self.ogb_dataset.data.y, dim=1)), 1)Line too long (95 > 79 characters):
55 val_split_idx = random_index[int(6 / 10 * dataset_size):int(8 / 10 * dataset_size)]Line too long (113 > 79 characters):
60 train_val_group_idx, test_group_idx = torch.tensor(train_val_group_idx), torch.tensor(test_group_idx)Line too long (104 > 79 characters):
63 split_idx = torch.zeros(len(torch.squeeze(self._metadata_array_wo_y)), dtype=torch.bool)Line too long (82 > 79 characters):
65 split_idx += (torch.squeeze(self._metadata_array_wo_y) == idx)Line too long (107 > 79 characters):
68 train_val_split_idx, test_split_idx = split_idx(train_val_group_idx), split_idx(test_group_idx)Line too long (100 > 79 characters):
70 train_val_split_idx = torch.arange(dataset_size, dtype=torch.int64)[train_val_split_idx]Line too long (98 > 79 characters):
73 train_split_idx = train_val_split_idx[random_index[:int(6 / 8 * train_val_sets_size)]]Line too long (96 > 79 characters):
74 val_split_idx = train_val_split_idx[random_index[int(6 / 8 * train_val_sets_size):]]Line too long (91 > 79 characters):
101 - prediction_fn (function): A function that turns y_pred into predicted labels.Line too long (106 > 79 characters):
102 Only None is supported because OGB Evaluators accept binary logitsLine too long (89 > 79 characters):
124 deg_inv = torch.where(deg > 0, 1. / torch.sqrt(deg), torch.zeros(deg.size()))Line too long (109 > 79 characters):
139 adj = _sym_normalize_adj(to_dense_adj(graph.edge_index, max_num_nodes=graph.x.size(0)).squeeze())Line too long (116 > 79 characters):
154 adj_feat[1:1 + node_feat_space.sum(), node, node] = convert(node_feat.unsqueeze(0), node_feat_space)