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
599b6042
Commit
599b6042
authored
Mar 14, 2018
by
rusty1s
Browse files
test closed spline backward
parent
e8e5841d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
test/test_spline_conv.py
test/test_spline_conv.py
+4
-4
No files found.
test/test_spline_conv.py
View file @
599b6042
...
...
@@ -50,13 +50,13 @@ def test_spline_conv_cpu(tensor):
def
test_spline_weighting_backward_cpu
():
for
degree
in
implemented_degrees
.
keys
():
kernel_size
=
torch
.
LongTensor
([
5
,
5
])
is_open_spline
=
torch
.
ByteTensor
([
1
,
1
])
kernel_size
=
torch
.
LongTensor
([
5
,
5
,
5
])
is_open_spline
=
torch
.
ByteTensor
([
1
,
0
,
1
])
op
=
SplineWeighting
(
kernel_size
,
is_open_spline
,
degree
)
x
=
torch
.
DoubleTensor
(
4
,
2
).
uniform_
(
-
1
,
1
)
x
=
torch
.
DoubleTensor
(
16
,
2
).
uniform_
(
-
1
,
1
)
x
=
Variable
(
x
)
pseudo
=
torch
.
DoubleTensor
(
4
,
2
).
uniform_
(
0
,
1
)
pseudo
=
torch
.
DoubleTensor
(
16
,
3
).
uniform_
(
0
,
1
)
pseudo
=
Variable
(
torch
.
DoubleTensor
(
pseudo
),
requires_grad
=
True
)
weight
=
torch
.
DoubleTensor
(
25
,
2
,
4
).
uniform_
(
-
1
,
1
)
weight
=
Variable
(
weight
)
...
...
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