Commit 95168d24 authored by rusty1s's avatar rusty1s
Browse files

docstrings contain images

parent 6b5be538
......@@ -3,11 +3,15 @@ from .utils import gen_output
def scatter_add_(output, index, input, dim=0):
r"""
|
.. image:: https://raw.githubusercontent.com/rusty1s/pytorch_scatter/
master/docs/source/_figures/add.svg?sanitize=true
:align: center
:width: 400px
|
Sums all values from the :attr:`input` tensor into :attr:`output` at the
indices specified in the :attr:`index` tensor along an given axis
:attr:`dim`. For each value in :attr:`input`, its output index is specified
......
......@@ -3,8 +3,18 @@ from .utils import gen_output
def scatter_div_(output, index, input, dim=0):
r"""Divides all values from the :attr:`input` tensor into :attr:`output`
at the indices specified in the :attr:`index` tensor along an given axis
r"""
|
.. image:: https://raw.githubusercontent.com/rusty1s/pytorch_scatter/
master/docs/source/_figures/div.svg?sanitize=true
:align: center
:width: 400px
|
Divides all values from the :attr:`input` tensor into :attr:`output` at
the indices specified in the :attr:`index` tensor along an given axis
:attr:`dim`. If multiple indices reference the same location, their
**contributions divide** (`cf.` :meth:`~torch_scatter.scatter_add_`).
......
......@@ -3,8 +3,18 @@ from .utils import gen_filled_tensor, gen_output
def scatter_max_(output, index, input, dim=0):
r"""Maximizes all values from the :attr:`input` tensor into :attr:`output`
at the indices specified in the :attr:`index` tensor along an given axis
r"""
|
.. image:: https://raw.githubusercontent.com/rusty1s/pytorch_scatter/
master/docs/source/_figures/max.svg?sanitize=true
:align: center
:width: 400px
|
Maximizes all values from the :attr:`input` tensor into :attr:`output` at
the indices specified in the :attr:`index` tensor along an given axis
:attr:`dim`. If multiple indices reference the same location, their
**contributions maximize** (`cf.` :meth:`~torch_scatter.scatter_add_`).
The second return value is the index location in :attr:`input` of each
......
......@@ -3,8 +3,18 @@ from .utils import gen_filled_tensor, gen_output
def scatter_mean_(output, index, input, dim=0):
r"""Averages all values from the :attr:`input` tensor into :attr:`output`
at the indices specified in the :attr:`index` tensor along an given axis
r"""
|
.. image:: https://raw.githubusercontent.com/rusty1s/pytorch_scatter/
master/docs/source/_figures/mean.svg?sanitize=true
:align: center
:width: 400px
|
Averages all values from the :attr:`input` tensor into :attr:`output` at
the indices specified in the :attr:`index` tensor along an given axis
:attr:`dim`. If multiple indices reference the same location, their
**contributions average** (`cf.` :meth:`~torch_scatter.scatter_add_`).
......
......@@ -3,8 +3,18 @@ from .utils import gen_filled_tensor, gen_output
def scatter_min_(output, index, input, dim=0):
r"""Minimizes all values from the :attr:`input` tensor into :attr:`output`
at the indices specified in the :attr:`index` tensor along an given axis
r"""
|
.. image:: https://raw.githubusercontent.com/rusty1s/pytorch_scatter/
master/docs/source/_figures/min.svg?sanitize=true
:align: center
:width: 400px
|
Minimizes all values from the :attr:`input` tensor into :attr:`output` at
the indices specified in the :attr:`index` tensor along an given axis
:attr:`dim`. If multiple indices reference the same location, their
**contributions minimize** (`cf.` :meth:`~torch_scatter.scatter_add_`).
The second return value is the index location in :attr:`input` of each
......
......@@ -3,8 +3,18 @@ from .utils import gen_output
def scatter_mul_(output, index, input, dim=0):
r"""Multiplies all values from the :attr:`input` tensor into :attr:`output`
at the indices specified in the :attr:`index` tensor along an given axis
r"""
|
.. image:: https://raw.githubusercontent.com/rusty1s/pytorch_scatter/
master/docs/source/_figures/mul.svg?sanitize=true
:align: center
:width: 400px
|
Multiplies all values from the :attr:`input` tensor into :attr:`output` at
the indices specified in the :attr:`index` tensor along an given axis
:attr:`dim`. If multiple indices reference the same location, their
**contributions multiply** (`cf.` :meth:`~torch_scatter.scatter_add_`).
......
......@@ -2,8 +2,18 @@ from .utils import gen_output
def scatter_sub_(output, index, input, dim=0):
r"""Subtracts all values from the :attr:`input` tensor into :attr:`output`
at the indices specified in the :attr:`index` tensor along an given axis
r"""
|
.. image:: https://raw.githubusercontent.com/rusty1s/pytorch_scatter/
master/docs/source/_figures/sub.svg?sanitize=true
:align: center
:width: 400px
|
Subtracts all values from the :attr:`input` tensor into :attr:`output` at
the indices specified in the :attr:`index` tensor along an given axis
:attr:`dim`. If multiple indices reference the same location, their
**negated contributions add** (`cf.` :meth:`~torch_scatter.scatter_add_`).
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment