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
torch-sparse
Commits
6a992437
Commit
6a992437
authored
May 22, 2020
by
rusty1s
Browse files
skip test in case metis is not found
parent
3bda3da8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
0 deletions
+7
-0
test/test_metis.py
test/test_metis.py
+7
-0
No files found.
test/test_metis.py
View file @
6a992437
...
@@ -4,7 +4,14 @@ from torch_sparse.tensor import SparseTensor
...
@@ -4,7 +4,14 @@ from torch_sparse.tensor import SparseTensor
from
.utils
import
devices
from
.utils
import
devices
try
:
torch
.
ops
.
torch_sparse
.
partition
with_metis
=
True
except
RuntimeError
:
with_metis
=
False
@
pytest
.
mark
.
skipif
(
not
with_metis
,
reason
=
'Not compiled with METIS support'
)
@
pytest
.
mark
.
parametrize
(
'device'
,
devices
)
@
pytest
.
mark
.
parametrize
(
'device'
,
devices
)
def
test_metis
(
device
):
def
test_metis
(
device
):
value1
=
torch
.
randn
(
6
*
6
,
device
=
device
).
view
(
6
,
6
)
value1
=
torch
.
randn
(
6
*
6
,
device
=
device
).
view
(
6
,
6
)
...
...
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