Backends/SiaNet.Backend.Torch/TypeGeneration.cs
/// <summary>
///   Adds the elements of tensor into the original tensor by selecting the indices in the order
///   given in index. The shape of tensor must exactly match the elements indexed or an error will be thrown.
/// </summary>
/// <param name="dim">Dimension to select for the add</param>
/// <param name="index">Entries to copy</param>
/// <param name="src">Tensor to copy the data from.</param>
Adds the elements of tensor into the original tensor by selecting the indices in the order
given in index. The shape of tensor must exactly match the elements indexed or an error will be thrown.
Adds the elements of tensor into the original tensor by selecting the indices in the order given in index . The shape of tensor must exactly match the elements indexed or an error will be thrown .
public void IndexAdd (int dim, LongTensor index, ShortTensor src)
        {
            if (src == null)
                throw new ArgumentNullException (nameof (src));
            if (index == null)
                throw new ArgumentNullException (nameof (index));
            THShortTensor_indexAdd (handle, dim, index.handle, src.handle);
        }
public void IndexAdd ( int dim , LongTensor index , ShortTensor src ) { if ( src == null ) throw new ArgumentNullException ( nameof ( src ) ) ; if ( index == null ) throw new ArgumentNullException ( nameof ( index ) ) ; THShortTensor_indexAdd ( handle , dim , index . handle , src . handle ) ; }
Adds the elements of tensor into the original tensor by selecting the indices in the order
given in index.
Adds the elements of tensor into the original tensor by selecting the indices in the order given in index .
dim
int
Dimension to select for the add
Dimension to select for the add
index
LongTensor
Entries to copy
Entries to copy
src
ShortTensor
Tensor to copy the data from.
Tensor to copy the data from .