Skip to content

Commit a9c7228

Browse files
committed
Update test_data.py
1 parent e0064b8 commit a9c7228

File tree

1 file changed

+15
-39
lines changed

1 file changed

+15
-39
lines changed

tests/unit/test_data.py

Lines changed: 15 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -35,50 +35,26 @@ def get_aspirin_graph(self):
3535

3636
# --- Node features: atomic numbers (C=6, O=8) ---
3737
# Shape of x : num_nodes x num_of_node_features
38+
# fmt: off
3839
x = torch.tensor(
3940
[
40-
[
41-
6
42-
], # C0 - This feature belongs to atom/node with `0` value in edge_index
43-
[
44-
6
45-
], # C1 - This feature belongs to atom/node with `1` value in edge_index
46-
[
47-
8
48-
], # O2 - This feature belongs to atom/node with `2` value in edge_index
49-
[
50-
8
51-
], # O3 - This feature belongs to atom/node with `3` value in edge_index
52-
[
53-
6
54-
], # C4 - This feature belongs to atom/node with `4` value in edge_index
55-
[
56-
6
57-
], # C5 - This feature belongs to atom/node with `5` value in edge_index
58-
[
59-
6
60-
], # C6 - This feature belongs to atom/node with `6` value in edge_index
61-
[
62-
6
63-
], # C7 - This feature belongs to atom/node with `7` value in edge_index
64-
[
65-
6
66-
], # C8 - This feature belongs to atom/node with `8` value in edge_index
67-
[
68-
6
69-
], # C9 - This feature belongs to atom/node with `9` value in edge_index
70-
[
71-
6
72-
], # C10 - This feature belongs to atom/node with `10` value in edge_index
73-
[
74-
8
75-
], # O11 - This feature belongs to atom/node with `11` value in edge_index
76-
[
77-
8
78-
], # O12 - This feature belongs to atom/node with `12` value in edge_index
41+
[6], # C0 - This feature belongs to atom/node with 0 value in edge_index
42+
[6], # C1 - This feature belongs to atom/node with 1 value in edge_index
43+
[8], # O2 - This feature belongs to atom/node with 2 value in edge_index
44+
[8], # O3 - This feature belongs to atom/node with 3 value in edge_index
45+
[6], # C4 - This feature belongs to atom/node with 4 value in edge_index
46+
[6], # C5 - This feature belongs to atom/node with 5 value in edge_index
47+
[6], # C6 - This feature belongs to atom/node with 6 value in edge_index
48+
[6], # C7 - This feature belongs to atom/node with 7 value in edge_index
49+
[6], # C8 - This feature belongs to atom/node with 8 value in edge_index
50+
[6], # C9 - This feature belongs to atom/node with 9 value in edge_index
51+
[6], # C10 - This feature belongs to atom/node with 10 value in edge_index
52+
[8], # O11 - This feature belongs to atom/node with 11 value in edge_index
53+
[8], # O12 - This feature belongs to atom/node with 12 value in edge_index
7954
],
8055
dtype=torch.float,
8156
)
57+
# fmt: on
8258

8359
# --- Edge list (bidirectional) ---
8460
# Shape of edge_index for undirected graph: 2 x num_of_edges; (2x26)

0 commit comments

Comments
 (0)