Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
dgl
Commits
aa17d78a
Unverified
Commit
aa17d78a
authored
Apr 27, 2020
by
Jinjing Zhou
Committed by
GitHub
Apr 27, 2020
Browse files
Fix (#1478)
parent
97bb85d5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
0 deletions
+2
-0
python/dgl/data/tu.py
python/dgl/data/tu.py
+2
-0
No files found.
python/dgl/data/tu.py
View file @
aa17d78a
...
...
@@ -75,6 +75,8 @@ class LegacyTUDataset(object):
try
:
DS_node_attr
=
np
.
loadtxt
(
self
.
_file_path
(
"node_attributes"
),
delimiter
=
","
)
if
DS_node_attr
.
ndim
==
1
:
DS_node_attr
=
np
.
expand_dims
(
DS_node_attr
,
-
1
)
for
idxs
,
g
in
zip
(
node_idx_list
,
self
.
graph_lists
):
g
.
ndata
[
'feat'
]
=
DS_node_attr
[
idxs
,
:]
self
.
data_mode
=
"node_attr"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment