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
ad6102e8
"vscode:/vscode.git/clone" did not exist on "2d9b97bc598d8d9ce6b0303d70070d8b905360ee"
Commit
ad6102e8
authored
Dec 20, 2017
by
rusty1s
Browse files
added formula
parent
b32abb95
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
torch_scatter/functions/__init__.py
torch_scatter/functions/__init__.py
+4
-2
No files found.
torch_scatter/functions/__init__.py
View file @
ad6102e8
import
torch
from
.scatter
import
scatter
from
.utils
import
gen_filled_tensor
,
gen_output
...
...
@@ -18,6 +16,10 @@ def scatter_add_(output, index, input, dim=0):
size :math:`(x_0, ..., x_{i-1}, y, x_{i+1}, ..., x_{n-1})`. Moreover, the
values of :attr:`index` must be between `0` and `output.size(dim) - 1`.
For one-dimensional tensors, the formula is given by
:math:`output_i = \sum_j input_j` where sum is over :math:`j` such that
:math:`index_j = i`.
Args:
output (Tensor): The destination tensor
index (LongTensor): The indices of elements to scatter
...
...
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