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-scatter
Commits
c541e366
Commit
c541e366
authored
Dec 18, 2017
by
rusty1s
Browse files
cleaner
parent
8c48dee0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
6 deletions
+1
-6
torch_scatter/functions/utils.py
torch_scatter/functions/utils.py
+1
-6
No files found.
torch_scatter/functions/utils.py
View file @
c541e366
...
...
@@ -12,10 +12,5 @@ def gen_filled_tensor(input, size, fill_value):
def
gen_output
(
index
,
input
,
dim
,
max_index
,
fill_value
):
max_index
=
index
.
max
()
+
1
if
max_index
is
None
else
max_index
size
=
list
(
index
.
size
())
if
torch
.
is_tensor
(
input
):
size
[
dim
]
=
max_index
else
:
size
[
dim
]
=
max_index
.
data
[
0
]
size
[
dim
]
=
max_index
if
torch
.
is_tensor
(
input
)
else
max_index
.
data
[
0
]
return
gen_filled_tensor
(
input
,
torch
.
Size
(
size
),
fill_value
)
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