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-spline-conv
Commits
62331ad9
Commit
62331ad9
authored
Apr 28, 2018
by
rusty1s
Browse files
cleaner
parent
08a517fe
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
torch_spline_conv/utils/ffi.py
torch_spline_conv/utils/ffi.py
+2
-2
No files found.
torch_spline_conv/utils/ffi.py
View file @
62331ad9
...
...
@@ -3,9 +3,9 @@ from .._ext import ffi
implemented_degrees
=
{
1
:
'linear'
,
2
:
'quadratic'
,
3
:
'cubic'
}
def
get_func
(
name
,
is_cuda
,
tensor
=
None
):
def
get_func
(
name
,
is_cuda
,
tensor
):
prefix
=
'THCC'
if
is_cuda
else
'TH'
prefix
+=
'Tensor'
if
tensor
is
None
else
tensor
.
type
().
split
(
'.'
)[
-
1
]
prefix
+=
tensor
.
type
().
split
(
'.'
)[
-
1
]
return
getattr
(
ffi
,
'{}_{}'
.
format
(
prefix
,
name
))
...
...
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