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-cluster
Commits
a353f274
Commit
a353f274
authored
Dec 19, 2018
by
rusty1s
Browse files
Merge branch 'master' of
https://github.com/rusty1s/pytorch_cluster
parents
eae34d5d
7ce4c1ca
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
cpu/grid.cpp
cpu/grid.cpp
+2
-2
No files found.
cpu/grid.cpp
View file @
a353f274
...
@@ -8,8 +8,8 @@ at::Tensor grid(at::Tensor pos, at::Tensor size, at::Tensor start,
...
@@ -8,8 +8,8 @@ at::Tensor grid(at::Tensor pos, at::Tensor size, at::Tensor start,
num_voxels
=
num_voxels
.
cumprod
(
0
);
num_voxels
=
num_voxels
.
cumprod
(
0
);
num_voxels
=
at
::
cat
({
at
::
ones
(
1
,
num_voxels
.
options
()),
num_voxels
},
0
);
num_voxels
=
at
::
cat
({
at
::
ones
(
1
,
num_voxels
.
options
()),
num_voxels
},
0
);
auto
index
=
empty
(
size
.
size
(
0
),
num_voxels
.
options
());
auto
index
=
at
::
empty
(
size
.
size
(
0
),
num_voxels
.
options
());
arange_out
(
index
,
size
.
size
(
0
));
at
::
arange_out
(
index
,
size
.
size
(
0
));
num_voxels
=
num_voxels
.
index_select
(
0
,
index
);
num_voxels
=
num_voxels
.
index_select
(
0
,
index
);
auto
cluster
=
(
pos
/
size
.
view
({
1
,
-
1
})).
toType
(
at
::
kLong
);
auto
cluster
=
(
pos
/
size
.
view
({
1
,
-
1
})).
toType
(
at
::
kLong
);
...
...
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