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
d772d390
Commit
d772d390
authored
Sep 25, 2018
by
Minjie Wang
Browse files
fix
parent
a8a4fcba
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
CMakeLists.txt
CMakeLists.txt
+1
-1
examples/pytorch/tree_lstm/train.py
examples/pytorch/tree_lstm/train.py
+1
-1
No files found.
CMakeLists.txt
View file @
d772d390
########################################
########################################
# Borrowed and adapted from TVM project
# Borrowed and adapted from TVM project
########################################
########################################
cmake_minimum_required
(
VERSION
3.2
)
cmake_minimum_required
(
VERSION
2.8
)
project
(
dgl C CXX
)
project
(
dgl C CXX
)
# Utility functions
# Utility functions
...
...
examples/pytorch/tree_lstm/train.py
View file @
d772d390
...
@@ -37,7 +37,7 @@ def main(args):
...
@@ -37,7 +37,7 @@ def main(args):
bg
=
dgl
.
batch
(
trees
)
bg
=
dgl
.
batch
(
trees
)
if
cuda
:
if
cuda
:
reprs
=
bg
.
get_n_repr
()
reprs
=
bg
.
get_n_repr
()
reprs
=
{
key
:
reprs
[
key
].
cuda
()}
reprs
=
{
key
:
val
.
cuda
()
for
key
,
val
in
reprs
.
items
()}
bg
.
set_n_repr
(
reprs
)
bg
.
set_n_repr
(
reprs
)
return
bg
return
bg
trainset
=
data
.
SST
()
trainset
=
data
.
SST
()
...
...
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