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
0e896a92
Unverified
Commit
0e896a92
authored
Jul 24, 2020
by
Da Zheng
Committed by
GitHub
Jul 24, 2020
Browse files
update. (#1857)
Co-authored-by:
Ubuntu
<
ubuntu@ip-172-31-30-164.us-west-2.compute.internal
>
parent
53fc6392
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
3 deletions
+3
-3
python/dgl/partition.py
python/dgl/partition.py
+1
-1
python/dgl/transform.py
python/dgl/transform.py
+1
-1
third_party/METIS
third_party/METIS
+1
-1
No files found.
python/dgl/partition.py
View file @
0e896a92
...
...
@@ -209,7 +209,7 @@ def metis_partition_assignment(g, k, balance_ntypes=None, balance_edges=False):
nids
=
F
.
asnumpy
(
F
.
nonzero_1d
(
balance_ntypes
==
ntype
))
degs
=
np
.
zeros
((
g
.
number_of_nodes
(),),
np
.
int64
)
degs
[
nids
]
=
F
.
asnumpy
(
g
.
in_degrees
(
nids
))
vwgt
.
append
(
F
.
tensor
(
degs
))
vwgt
.
append
(
F
.
zerocopy_from_numpy
(
degs
))
# The vertex weights have to be stored in a vector.
if
len
(
vwgt
)
>
0
:
...
...
python/dgl/transform.py
View file @
0e896a92
...
...
@@ -1078,7 +1078,7 @@ def metis_partition_assignment(g, k, balance_ntypes=None, balance_edges=False):
nids
=
F
.
asnumpy
(
F
.
nonzero_1d
(
balance_ntypes
==
ntype
))
degs
=
np
.
zeros
((
g
.
number_of_nodes
(),),
np
.
int64
)
degs
[
nids
]
=
F
.
asnumpy
(
g
.
in_degrees
(
nids
))
vwgt
.
append
(
F
.
tensor
(
degs
))
vwgt
.
append
(
F
.
zerocopy_from_numpy
(
degs
))
# The vertex weights have to be stored in a vector.
if
len
(
vwgt
)
>
0
:
...
...
METIS
@
62d658c0
Compare
b4090805
...
62d658c0
Subproject commit
b40908054eac6abeadd46fa55464f0068fc052dc
Subproject commit
62d658c0bcd8dbc8cedf7489fa834403b09382f5
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