tensor

package
v0.3.13 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 7, 2021 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Examples

Constants

View Source
const (
	NpyMagicString string = "\x93NUMPY"
	NpySuffix      string = ".npy"
)

Variables

View Source
var None = NewTensor()

None is an undefined tensor. It can be used in optional tensor parameter where 'None' value used. `ts.MustDefined()` function is used for checking 'null'

Functions

func CMalloc

func CMalloc(nbytes int) (dataPtr unsafe.Pointer, buf *bytes.Buffer)

CMalloc allocates a given number of bytes to C side memory. It returns - dataPtr: a C pointer type of `*void` (`unsafe.Pointer` in Go). - buf : a Go pointer points to a given bytes of buffer (empty) in C memory allocated by C waiting for writing data to.

NOTE: 1. Go pointer is a pointer to Go memory. C pointer is a pointer to C memory. 2. General rule is Go code can use C pointers. Go code may pass Go pointer to C provided that the Go memory to which it points does NOT contain any Go pointers. BUT C code must not store any Go pointers in Go memory, even temporarily. 3. Some Go values contain Go pointers IMPLICITLY: strings, slices, maps, channels and function values. Thus, pointers to these values should not be passed to C side. Instead, data should be allocated to C memory and return a C pointer to it using `C.malloc`. Ref: https://github.com/golang/proposal/blob/master/design/12416-cgo-pointers.md

func Copy_

func Copy_(self, src *Tensor)

Copy_ copies in-place values from the argument tensor to the input tensor.

func DataAsPtr

func DataAsPtr(data interface{}) (dataPtr unsafe.Pointer, err error)

DataAsPtr write to C memory and returns a C pointer.

NOTE: Supported data types are scalar, slice/array of scalar type equivalent to DType.

func DataCheck

func DataCheck(data interface{}) (k reflect.Type, n int, err error)

DataCheck checks the input data for element Go type and number of elements. It will return errors if element type is not supported.

func DataDim

func DataDim(data interface{}) (retVal int, err error)

DataDim returns number of elements in data NOTE: only support scalar and (nested) slice/array of scalar type

func DecodeTensor

func DecodeTensor(r *bytes.Reader, shape []int64, typ reflect.Type, ptr reflect.Value) error

DecodeTensor decodes tensor value from a C memory buffer given C pointer, data type and shape and returns data value of type interface

func ElementCount

func ElementCount(shape []int64) int64

ElementCount counts number of element in the tensor given a shape

func EncodeTensor

func EncodeTensor(w *bytes.Buffer, v reflect.Value, shape []int64) error

EncodeTensor loads tensor data to C memory and returns a C pointer.

func FlattenData

func FlattenData(data interface{}) (fData interface{}, err error)

FlattenData flattens data to 1D array ([]T)

func FlattenDim

func FlattenDim(shape []int64) int

FlattenDim counts number of elements with given shape

func GradSetEnabled

func GradSetEnabled(b bool) (bool, error)

GradSetEnabled sets globally whether GradMode gradient accumulation is enable or not. It returns PREVIOUS state of Grad before setting.

func InvokeFnWithArgs

func InvokeFnWithArgs(fn interface{}, args ...string)

InvokeFn reflects and invokes a function of interface type.

func MustGradSetEnabled

func MustGradSetEnabled(b bool) bool

MustGradSetEnabled sets globally whether GradMode gradient accumuation is enable or not. It returns PREVIOUS state of Grad before setting. It will be panic if error

func MustSaveMulti

func MustSaveMulti(namedTensors []NamedTensor, path string)

MustSaveMulti saves some named tensors to a file. It will panic if error

NOTE. This method is depreciated and will be replaced with `MustSaveMultiNew`

func NoGrad

func NoGrad(fn interface{})

NoGrad runs a closure without keeping track of gradients.

func NoGrad1

func NoGrad1(fn func() interface{}) interface{}

func SaveHwc

func SaveHwc(ts *Tensor, path string) error

SaveHwc save an image from tensor. It expects a tensor of shape [height, width, channels]

func SaveMulti

func SaveMulti(namedTensors []NamedTensor, path string) error

SaveMulti saves some named tensors to a file

The file format is the same as the one used by the PyTorch C++ API. NOTE. This method is depreciated and will be replaced with `SaveMultiNew`

func SaveMultiNew added in v0.1.10

func SaveMultiNew(namedTensors []NamedTensor, path string) error

SaveMultiNew saves a slice of named tensors to the given file path.

func TorchErr

func TorchErr() error

TorchErr checks and retrieves last error message from C `thread_local` if existing and frees up C memory the C pointer points to.

NOTE: Go language atm does not have generic function something similar to `macro` in Rust language, does it? So we have to wrap this function to any Libtorch C function call to check error instead of doing the other way around. See Go2 proposal: https://github.com/golang/go/issues/32620

Types

type CIValue

type CIValue struct {
	// contains filtered or unexported fields
}

type CModule

type CModule struct {
	Cmodule lib.Cmodule
}

A JIT PyTorch module.

These modules can be created via the [TorchScript python api](https://pytorch.org/docs/stable/jit.html).

func ModuleLoad

func ModuleLoad(path string) (*CModule, error)

Loads a PyTorch saved JIT model from a file.

func ModuleLoadData

func ModuleLoadData(stream io.Reader) (*CModule, error)

Loads a PyTorch saved JIT model from a read instance.

func ModuleLoadDataOnDevice

func ModuleLoadDataOnDevice(stream io.Reader, device gotch.Device) (*CModule, error)

Loads a PyTorch saved JIT model from a read instance.

This function loads the model directly on the specified device, which means it also allows loading a GPU model on the CPU without having a CUDA enabled GPU.

func ModuleLoadOnDevice

func ModuleLoadOnDevice(path string, device gotch.Device) (*CModule, error)

Loads a PyTorch saved JIT model from a file onto the given device.

This function loads the model directly on the specified device, which means it also allows loading a GPU model on the CPU without having a CUDA enabled GPU.

func (*CModule) Drop

func (cm *CModule) Drop()

func (*CModule) Forward

func (cm *CModule) Forward(tensor *Tensor) (*Tensor, error)

Forwad implements Module interface for CModule.

func (*CModule) ForwardIs

func (cm *CModule) ForwardIs(ivalues []IValue) (*IValue, error)

ForwardIs performs the forward pass for a model on some specified ivalue input.

func (*CModule) ForwardTs

func (cm *CModule) ForwardTs(tensors []Tensor) (*Tensor, error)

ForwardTs performs the forward pass for a model on some specified tensor inputs.

func (*CModule) GetProfilingMode added in v0.3.7

func (cm *CModule) GetProfilingMode() bool

GetProfilingMode get CModule profiling mode

func (*CModule) NamedParameters added in v0.3.7

func (cm *CModule) NamedParameters() ([]NamedTensor, error)

NamedParameters loads some named tensors from a module.

func (*CModule) Save added in v0.3.7

func (cm *CModule) Save(file string) error

Save save CModule to a specified path.

func (*CModule) SetEval added in v0.3.7

func (cm *CModule) SetEval()

SetEval set CModule to inference mode

func (*CModule) SetProfilingMode added in v0.3.7

func (cm *CModule) SetProfilingMode(b bool)

SetProfilingMode set CModule profiling mode

func (*CModule) SetTrain added in v0.3.7

func (cm *CModule) SetTrain()

SetTrain set CModule to train mode

func (*CModule) To

func (cm *CModule) To(device gotch.Device, kind gotch.DType, nonBlocking bool)

To moves CModule to specified device.

type COptimizer

type COptimizer struct {
	// contains filtered or unexported fields
}

func Adam

func Adam(lr, beta1, beta2, weightDecay float64) (*COptimizer, error)

Adam returns Adam optimizer

func AdamW added in v0.3.11

func AdamW(lr, beta1, beta2, weightDecay float64) (*COptimizer, error)

AdamW returns AdamW optimizer

func RmsProp

func RmsProp(lr, alpha, eps, wd, momentum float64, centered bool) (*COptimizer, error)

RmsProp returns RMSProp optimizer

func Sgd

func Sgd(lr, momentum, dampening, wd float64, nesterov bool) (*COptimizer, error)

Sgd returns SGD optimizer

func (*COptimizer) AddParamGroup added in v0.3.10

func (co *COptimizer) AddParamGroup(tensors []Tensor) error

func (*COptimizer) AddParameter added in v0.3.10

func (co *COptimizer) AddParameter(param *Tensor, group uint) error

AddParameter adds a single parameter to parameter group.

func (*COptimizer) AddParameters

func (co *COptimizer) AddParameters(tensors []Tensor) error

AddParameters adds parameters as a slice of tensors to optimizer

func (*COptimizer) Drop

func (co *COptimizer) Drop()

Drop removes optimizer and frees up memory.

func (*COptimizer) GetLearningRates added in v0.3.10

func (co *COptimizer) GetLearningRates() ([]float64, error)

GetLeanringRates get learning rates for the optimizer

func (*COptimizer) ParamGroupNum added in v0.3.10

func (co *COptimizer) ParamGroupNum() (int64, error)

func (*COptimizer) SetLearningRate

func (co *COptimizer) SetLearningRate(lr float64) error

SetLeanringRate sets learning rate for the optimizer

func (*COptimizer) SetLearningRates added in v0.3.10

func (co *COptimizer) SetLearningRates(lrs []float64) error

func (*COptimizer) SetMomentum

func (co *COptimizer) SetMomentum(m float64) error

SetMomentum sets a momentum for the optimizer

func (*COptimizer) Step

func (co *COptimizer) Step() error

Steps proceeds optimizer

func (*COptimizer) ZeroGrad

func (co *COptimizer) ZeroGrad() error

ZeroGrad sets gradients to zero

type Func

type Func struct {
	// contains filtered or unexported fields
}

func NewFunc

func NewFunc(fn interface{}) (retVal Func, err error)

func (*Func) Info

func (f *Func) Info() (retVal FuncInfo)

Info analyzes input of interface type and returns function information in FuncInfo struct. It returns error if input is not a function type under the hood. It will be panic if input is not a function

func (*Func) Invoke

func (f *Func) Invoke() interface{}

type FuncInfo

type FuncInfo struct {
	Signature  string
	InArgs     []reflect.Value
	OutArgs    []reflect.Value
	IsVariadic bool
}

Func struct contains information of a function

type IValue

type IValue struct {
	// contains filtered or unexported fields
}

func IValueFromC

func IValueFromC(cval *CIValue) (*IValue, error)

IValueFromC returns an IValue from given CIValue.

It consumes the pointer and frees the associated memory.

func NewIValue

func NewIValue(v interface{}) *IValue

NewIValue creates a new IValue from given value of various types.

func (*IValue) Kind

func (iv *IValue) Kind() IValueKind

func (*IValue) Name

func (iv *IValue) Name() string

func (*IValue) ToCIValue

func (iv *IValue) ToCIValue() (*CIValue, error)

func (*IValue) Value

func (iv *IValue) Value() interface{}

type IValueKind

type IValueKind struct {
	reflect.Type
}
var (
	NoneVal        IValueKind = IValueKind{reflect.TypeOf(nil)}
	TensorVal      IValueKind = IValueKind{reflect.TypeOf(Tensor{})}
	DoubleVal      IValueKind = IValueKind{reflect.TypeOf(float64(1))}
	IntVal         IValueKind = IValueKind{reflect.TypeOf(int64(1))}
	BoolVal        IValueKind = IValueKind{reflect.TypeOf(true)}
	TupleVal       IValueKind = IValueKind{reflect.TypeOf([]IValue{})}
	IntListVal     IValueKind = IValueKind{reflect.TypeOf([]int64{})}
	DoubleListVal  IValueKind = IValueKind{reflect.TypeOf([]float64{})}
	BoolListVal    IValueKind = IValueKind{reflect.TypeOf([]bool{})}
	StringVal      IValueKind = IValueKind{reflect.TypeOf("")}
	TensorListVal  IValueKind = IValueKind{reflect.TypeOf([]Tensor{})}
	GenericListVal IValueKind = IValueKind{reflect.TypeOf([]IValue{})}
	GenericDictVal IValueKind = IValueKind{reflect.TypeOf(map[IValue]IValue{})} // 2 elements. ? map[IValue]IValue
	GenericVal     IValueKind = IValueKind{reflect.TypeOf(IValue{})}
)

type IndexOp

type IndexOp interface {
	Idx(index interface{}) Tensor
}

type IndexSelect

type IndexSelect struct{ Index *Tensor }

func NewIndexSelect

func NewIndexSelect(ts *Tensor) IndexSelect

func NewSliceIndex

func NewSliceIndex(sl []int64) IndexSelect

type InsertNewAxis

type InsertNewAxis struct{}

func NewInsertNewAxis

func NewInsertNewAxis() InsertNewAxis

type Iter2

type Iter2 struct {
	// contains filtered or unexported fields
}

Iter2 is an iterator over a pair of tensors which have the same first dimension size. The typical use case is to iterate over batches. Each batch is a pair containing a (potentially random) slice of each of the two input tensors.

func MustNewIter2

func MustNewIter2(xs, ys *Tensor, batchSize int64) *Iter2

MustNewIter2 returns a new iterator.

This takes as input two tensors which first dimension must match. The returned iterator can be used to range over mini-batches of data of specified size. Panics if `xs` and `ys` have different first dimension sizes.

Arguments

* `xs` - the features to be used by the model. * `ys` - the targets that the model attempts to predict. * `batch_size` - the size of batches to be returned.

func NewIter2

func NewIter2(xs, ys *Tensor, batchSize int64) (*Iter2, error)

NewIter2 returns a new iterator.

This takes as input two tensors which first dimension must match. The returned iterator can be used to range over mini-batches of data of specified size. An error is returned if `xs` and `ys` have different first dimension sizes.

Arguments

* `xs` - the features to be used by the model. * `ys` - the targets that the model attempts to predict. * `batch_size` - the size of batches to be returned.

func (*Iter2) Drop

func (it *Iter2) Drop()

func (*Iter2) Next

func (it *Iter2) Next() (item Iter2Item, ok bool)

Next implements iterator for Iter2

func (*Iter2) ReturnSmallLastBatch

func (it *Iter2) ReturnSmallLastBatch() *Iter2

ReturnSmallLastBatch when set, returns the last batch even if smaller than the batch size.

func (*Iter2) Shuffle

func (it *Iter2) Shuffle()

Shuffle shuffles the dataset.

The iterator would still run over the whole dataset but the order in which elements are grouped in mini-batches is randomized.

func (*Iter2) ToDevice

func (it *Iter2) ToDevice(device gotch.Device) *Iter2

ToDevice transfers the mini-batches to a specified device.

type Iter2Item

type Iter2Item struct {
	Data  *Tensor
	Label *Tensor
}

type Iterable

type Iterable struct {
	Index    int64
	Len      int64
	Content  *Tensor
	ItemKind gotch.DType
}

func (*Iterable) Next

func (it *Iterable) Next() (item interface{}, ok bool)

Next implements Iterator interface

type Iterator

type Iterator interface {
	Next() (item interface{}, ok bool)
}

type Module

type Module interface {
	// ModuleT
	Forward(xs *Tensor) *Tensor
}

Module interface is a container with only one method `Forward`

The following is `module` concept from Pytorch documenation: Base class for all neural network modules. Your models should also subclass this class. Modules can also contain other Modules, allowing to nest them in a tree structure. You can assign the submodules as regular attributes. Submodules assigned in this way will be registered, and will have their parameters converted too when you call .cuda(), etc.

type ModuleOption

type ModuleOption func() Module

func WithModule

func WithModule(m Module) ModuleOption

type ModuleT

type ModuleT interface {
	// Forward(xs Tensor) Tensor
	ForwardT(xs *Tensor, train bool) *Tensor
}

ModuleT is a `Module` with an additional train parameter The train parameter is commonly used to have different behavior between training and evaluation. E.g. When using dropout or batch-normalization.

type ModuleTOption

type ModuleTOption func() ModuleT

func WithModuleT

func WithModuleT(m ModuleT) ModuleTOption

type NamedTensor

type NamedTensor struct {
	Name   string
	Tensor *Tensor
}

NamedTensor wraps C tensor and its name

func LoadMulti

func LoadMulti(path string) ([]NamedTensor, error)

LoadMulti loads some named tensors from a file

The file format is the same as the one used by the PyTorch C++ API.

func LoadMultiWithDevice

func LoadMultiWithDevice(path string, device gotch.Device) ([]NamedTensor, error)

LoadMultiWithDevice loads some named tensors from a file to a given device

The file format is the same as the one used by the PyTorch C++ API.

func MustLoadMulti

func MustLoadMulti(path string) []NamedTensor

MustLoadMulti loads some named tensors from a file. It will panic if error

func MustLoadMultiWithDevice

func MustLoadMultiWithDevice(path string, device gotch.Device) []NamedTensor

MustLoadMulti loads some named tensors from a file. It will panic if error

func ReadNpz added in v0.3.3

func ReadNpz(filePath string) ([]NamedTensor, error)

ReadNpz reads a compressed numpy file (.npz) and returns named tensors

type Narrow

type Narrow struct {
	Start int64
	End   int64
}

func NewNarrow

func NewNarrow(start, end int64) Narrow

type NewAxis

type NewAxis struct{}

type NoGradGuard

type NoGradGuard struct {
	// contains filtered or unexported fields
}

NoGradGuard is a RAII guard that prevents gradient tracking until deallocated. It actually sets a global flag that is checked by the backend whenever an op is done on a variable. The guard itself saved the current status and set it to false in the constructor. And restore the saved status in it’s destructor. That way it is similar to a with torch.no_grad(): block in python. Ref. https://discuss.pytorch.org/t/how-does-nogradguard-works-in-cpp/34960/2

TODO: should we implement Go `mutex` here???

func NewNoGradGuard

func NewNoGradGuard() *NoGradGuard

Init NoGradGuard and disables gradient tracking

func (*NoGradGuard) Drop

func (ngg *NoGradGuard) Drop()

Drop drops the NoGradGuard state.

func (*NoGradGuard) Enable

func (ngg *NoGradGuard) Enable()

type NpyHeader added in v0.3.3

type NpyHeader struct {
	// contains filtered or unexported fields
}

func NewNpyHeader added in v0.3.3

func NewNpyHeader(dtype gotch.DType, fo bool, shape []int64) *NpyHeader

NewHeader creates Header from input data

NOTE. This is mainly for unit test purpose

func ParseNpyHeader added in v0.3.3

func ParseNpyHeader(header string) (*NpyHeader, error)

ParseNpyHeader parses the given npy header string.

A typical example would be: {'descr': '<f8', 'fortran_order': False, 'shape': (128,), }

func (*NpyHeader) ToString added in v0.3.3

func (h *NpyHeader) ToString() (string, error)

type Reduction

type Reduction int

Reduction type is an enum-like type

const (
	// Do not reduce
	ReductionNone Reduction = iota
	// Mean of losses
	ReductionMean
	// Sum of losses
	ReductionSum
	// Escape hatch in case new options become available
	ReductionOther
)

func (Reduction) ToInt

func (r Reduction) ToInt() int

type Scalar

type Scalar struct {
	// contains filtered or unexported fields
}

func FloatScalar

func FloatScalar(v float64) *Scalar

FloatScalar creates a float scalar

func IntScalar

func IntScalar(v int64) *Scalar

IntScalar creates a integer scalar

func (*Scalar) Drop

func (sc *Scalar) Drop() (err error)

Drop sets scalar to zero and frees up C memory

TODO: Really? after running s.Drop() and s.ToInt() it returns Zero.

func (*Scalar) MustDrop

func (sc *Scalar) MustDrop()

func (*Scalar) ToFloat

func (sc *Scalar) ToFloat() (retVal float64, err error)

ToFloat returns a float value

func (*Scalar) ToInt

func (sc *Scalar) ToInt() (retVal int64, err error)

ToInt returns a integer value

func (*Scalar) ToString

func (sc *Scalar) ToString() (retVal string, err error)

ToString returns a string representation of scalar value

type Select

type Select struct{ Index int64 }

func NewSelect

func NewSelect(index int64) Select

NewSelect creates an tensor indexer with given index. `index` must be in range of tensor dimension. E.g. tensor shape [2,8] will have size = 2, hence `index` should be in range from [0,2)

type Tensor

type Tensor struct {
	// contains filtered or unexported fields
}

func AffineGridGenerator

func AffineGridGenerator(theta *Tensor, size []int64, alignCorners bool) (retVal *Tensor, err error)

func AffineGridGeneratorBackward

func AffineGridGeneratorBackward(grad *Tensor, size []int64, alignCorners bool) (retVal *Tensor, err error)

func AlignTensors

func AlignTensors(tensors []Tensor) (retVal []Tensor, err error)

tensor *atg_align_tensors(tensor *tensors_data, int tensors_len);

func AlphaDropout

func AlphaDropout(input *Tensor, p float64, train bool) (retVal *Tensor, err error)

func Arange

func Arange(end *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func Arange1

func Arange1(start *Scalar, end *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func Arange2

func Arange2(start *Scalar, end *Scalar, step *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func ArangeOut

func ArangeOut(out *Tensor, end *Scalar) (retVal *Tensor, err error)

func ArangeOut1

func ArangeOut1(out *Tensor, start *Scalar, end *Scalar) (retVal *Tensor, err error)

func BartlettWindow

func BartlettWindow(windowLength int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func BartlettWindow1

func BartlettWindow1(windowLength int64, periodic bool, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func BatchNorm

func BatchNorm(input *Tensor, weight *Tensor, bias *Tensor, runningMean *Tensor, runningVar *Tensor, training bool, momentum float64, eps float64, cudnnEnabled bool) (retVal *Tensor, err error)

func BatchNormBackwardElemt

func BatchNormBackwardElemt(gradOut *Tensor, input *Tensor, mean *Tensor, invstd *Tensor, weight *Tensor, meanDy *Tensor, meanDyXmu *Tensor) (retVal *Tensor, err error)

func BatchNormElemt

func BatchNormElemt(input *Tensor, weight *Tensor, bias *Tensor, mean *Tensor, invstd *Tensor, eps float64) (retVal *Tensor, err error)

func BatchNormElemtOut

func BatchNormElemtOut(out *Tensor, input *Tensor, weight *Tensor, bias *Tensor, mean *Tensor, invstd *Tensor, eps float64) (retVal *Tensor, err error)

func Bilinear

func Bilinear(input1 *Tensor, input2 *Tensor, weight *Tensor, bias *Tensor) (retVal *Tensor, err error)

func Binomial added in v0.3.0

func Binomial(count *Tensor, prob *Tensor) (retVal *Tensor, err error)

func BlackmanWindow

func BlackmanWindow(windowLength int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func BlackmanWindow1

func BlackmanWindow1(windowLength int64, periodic bool, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func BlockDiag added in v0.3.0

func BlockDiag(tensors []Tensor) (retVal *Tensor, err error)

func BroadcastTensors

func BroadcastTensors(tensors []Tensor) (retVal []Tensor, err error)

tensor *atg_broadcast_tensors(tensor *tensors_data, int tensors_len);

func Bucketize1 added in v0.3.0

func Bucketize1(selfScalar *Scalar, boundaries *Tensor, outInt32 bool, right bool) (retVal *Tensor, err error)

func CartesianProd

func CartesianProd(tensors []Tensor) (retVal *Tensor, err error)

func Cat

func Cat(tensors []Tensor, dim int64) (retVal *Tensor, err error)

func CatOut

func CatOut(out *Tensor, tensors []Tensor, dim int64) (retVal *Tensor, err error)

func Cdist

func Cdist(x1 *Tensor, x2 *Tensor, p float64, computeMode []int64) (retVal *Tensor, err error)

func ChainMatmul

func ChainMatmul(matrices []Tensor) (retVal *Tensor, err error)

func Col2imBackward

func Col2imBackward(gradOutput *Tensor, kernelSize []int64, dilation []int64, padding []int64, stride []int64) (retVal *Tensor, err error)

func Col2imBackwardOut

func Col2imBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, dilation []int64, padding []int64, stride []int64) (retVal *Tensor, err error)

func Complex added in v0.3.0

func Complex(real *Tensor, imag *Tensor) (retVal *Tensor, err error)

func ComplexOut added in v0.3.0

func ComplexOut(out *Tensor, real *Tensor, imag *Tensor) (retVal *Tensor, err error)

func Conv1d

func Conv1d(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, groups int64) (retVal *Tensor, err error)

func Conv2d

func Conv2d(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, groups int64) (retVal *Tensor, err error)

func Conv3d

func Conv3d(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, groups int64) (retVal *Tensor, err error)

func ConvTranspose1d

func ConvTranspose1d(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, groups int64, dilation []int64) (retVal *Tensor, err error)

func ConvTranspose2d

func ConvTranspose2d(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, groups int64, dilation []int64) (retVal *Tensor, err error)

func ConvTranspose3d

func ConvTranspose3d(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, groups int64, dilation []int64) (retVal *Tensor, err error)

func Convolution

func Convolution(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, transposed bool, outputPadding []int64, groups int64) (retVal *Tensor, err error)

func ConvolutionOverrideable

func ConvolutionOverrideable(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, transposed bool, outputPadding []int64, groups int64) (retVal *Tensor, err error)

func CosineEmbeddingLoss

func CosineEmbeddingLoss(input1 *Tensor, input2 *Tensor, target *Tensor, margin float64, reduction int64) (retVal *Tensor, err error)

func CosineSimilarity

func CosineSimilarity(x1 *Tensor, x2 *Tensor, dim int64, eps float64) (retVal *Tensor, err error)

func CtcLoss

func CtcLoss(logProbs *Tensor, targets *Tensor, inputLengths []int64, targetLengths []int64, blank int64, reduction int64, zeroInfinity bool) (retVal *Tensor, err error)

func CtcLoss1

func CtcLoss1(logProbs *Tensor, targets *Tensor, inputLengths *Tensor, targetLengths *Tensor, blank int64, reduction int64, zeroInfinity bool) (retVal *Tensor, err error)

func CudnnAffineGridGenerator

func CudnnAffineGridGenerator(theta *Tensor, n int64, c int64, h int64, w int64) (retVal *Tensor, err error)

func CudnnAffineGridGeneratorBackward

func CudnnAffineGridGeneratorBackward(grad *Tensor, n int64, c int64, h int64, w int64) (retVal *Tensor, err error)

func CudnnConvolutionBackwardInput

func CudnnConvolutionBackwardInput(selfSize []int64, gradOutput *Tensor, weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, allowTf32 bool) (retVal *Tensor, err error)

func CudnnConvolutionTransposeBackwardInput

func CudnnConvolutionTransposeBackwardInput(gradOutput *Tensor, weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, allowTf32 bool) (retVal *Tensor, err error)

func CummaxminBackward added in v0.3.0

func CummaxminBackward(grad *Tensor, input *Tensor, indices *Tensor, dim int64) (retVal *Tensor, err error)

func CumprodBackward added in v0.3.0

func CumprodBackward(grad *Tensor, input *Tensor, dim int64) (retVal *Tensor, err error)

func DiagBackward added in v0.3.0

func DiagBackward(grad *Tensor, inputSizes []int64, diagonal int64) (retVal *Tensor, err error)

func DiagonalBackward added in v0.3.0

func DiagonalBackward(grad *Tensor, inputSizes []int64, offset int64, dim1 int64, dim2 int64) (retVal *Tensor, err error)

func Dropout

func Dropout(input *Tensor, p float64, train bool) (retVal *Tensor, err error)

func Dstack added in v0.3.0

func Dstack(tensors []Tensor) (retVal *Tensor, err error)

func DstackOut added in v0.3.0

func DstackOut(out *Tensor, tensors []Tensor) (retVal *Tensor, err error)

func Einsum

func Einsum(equation string, tensors []Tensor) (retVal *Tensor, err error)

func EluBackward

func EluBackward(gradOutput *Tensor, alpha *Scalar, scale *Scalar, inputScale *Scalar, output *Tensor) (retVal *Tensor, err error)

func EluBackwardOut

func EluBackwardOut(gradInput *Tensor, gradOutput *Tensor, alpha *Scalar, scale *Scalar, inputScale *Scalar, output *Tensor) (retVal *Tensor, err error)

func Embedding

func Embedding(weight *Tensor, indices *Tensor, paddingIdx int64, scaleGradByFreq bool, sparse bool) (retVal *Tensor, err error)

func EmbeddingBackward

func EmbeddingBackward(grad *Tensor, indices *Tensor, numWeights int64, paddingIdx int64, scaleGradByFreq bool, sparse bool) (retVal *Tensor, err error)

func EmbeddingDenseBackward

func EmbeddingDenseBackward(gradOutput *Tensor, indices *Tensor, numWeights int64, paddingIdx int64, scaleGradByFreq bool) (retVal *Tensor, err error)

func EmbeddingSparseBackward

func EmbeddingSparseBackward(grad *Tensor, indices *Tensor, numWeights int64, paddingIdx int64, scaleGradByFreq bool) (retVal *Tensor, err error)

func Empty

func Empty(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func EmptyMeta added in v0.3.0

func EmptyMeta(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func EmptyOut

func EmptyOut(out *Tensor, size []int64) (retVal *Tensor, err error)

func EmptyQuantized added in v0.3.0

func EmptyQuantized(size []int64, qtensor *Tensor) (retVal *Tensor, err error)

func EmptyStrided

func EmptyStrided(size []int64, stride []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func Eye

func Eye(n int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func Eye1

func Eye1(n int64, m int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func EyeOut

func EyeOut(out *Tensor, n int64) (retVal *Tensor, err error)

func EyeOut1

func EyeOut1(out *Tensor, n int64, m int64) (retVal *Tensor, err error)

func FbgemmLinearFp16Weight

func FbgemmLinearFp16Weight(input *Tensor, packedWeight *Tensor, bias *Tensor) (retVal *Tensor, err error)

func FbgemmLinearFp16WeightFp32Activation

func FbgemmLinearFp16WeightFp32Activation(input *Tensor, packedWeight *Tensor, bias *Tensor) (retVal *Tensor, err error)

func FbgemmLinearInt8Weight

func FbgemmLinearInt8Weight(input *Tensor, weight *Tensor, packed *Tensor, colOffsets *Tensor, weightScale *Scalar, weightZeroPoint *Scalar, bias *Tensor) (retVal *Tensor, err error)

func FbgemmLinearInt8WeightFp32Activation

func FbgemmLinearInt8WeightFp32Activation(input *Tensor, weight *Tensor, packed *Tensor, colOffsets *Tensor, weightScale *Scalar, weightZeroPoint *Scalar, bias *Tensor) (retVal *Tensor, err error)

func FbgemmPackGemmMatrixFp16

func FbgemmPackGemmMatrixFp16(input *Tensor) (retVal *Tensor, err error)

func FbgemmPackQuantizedMatrix

func FbgemmPackQuantizedMatrix(input *Tensor) (retVal *Tensor, err error)

func FbgemmPackQuantizedMatrix1

func FbgemmPackQuantizedMatrix1(input *Tensor, k int64, n int64) (retVal *Tensor, err error)

func FeatureAlphaDropout

func FeatureAlphaDropout(input *Tensor, p float64, train bool) (retVal *Tensor, err error)

func FeatureDropout

func FeatureDropout(input *Tensor, p float64, train bool) (retVal *Tensor, err error)

func FromFile

func FromFile(filename string, shared bool, size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func Full

func Full(size []int64, fillValue *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func FullOut

func FullOut(out *Tensor, size []int64, fillValue *Scalar) (retVal *Tensor, err error)

func GridSampler

func GridSampler(input *Tensor, grid *Tensor, interpolationMode int64, paddingMode int64, alignCorners bool) (retVal *Tensor, err error)

func GridSampler2d

func GridSampler2d(input *Tensor, grid *Tensor, interpolationMode int64, paddingMode int64, alignCorners bool) (retVal *Tensor, err error)

func GridSampler3d

func GridSampler3d(input *Tensor, grid *Tensor, interpolationMode int64, paddingMode int64, alignCorners bool) (retVal *Tensor, err error)

func GroupNorm

func GroupNorm(input *Tensor, numGroups int64, weight *Tensor, bias *Tensor, eps float64, cudnnEnabled bool) (retVal *Tensor, err error)

func GruCell

func GruCell(input *Tensor, hx *Tensor, wIh *Tensor, wHh *Tensor, bIh *Tensor, bHh *Tensor) (retVal *Tensor, err error)

func HammingWindow

func HammingWindow(windowLength int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func HammingWindow1

func HammingWindow1(windowLength int64, periodic bool, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func HammingWindow2

func HammingWindow2(windowLength int64, periodic bool, alpha float64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func HammingWindow3

func HammingWindow3(windowLength int64, periodic bool, alpha float64, beta float64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func HannWindow

func HannWindow(windowLength int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func HannWindow1

func HannWindow1(windowLength int64, periodic bool, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func Hspmm

func Hspmm(mat1 *Tensor, mat2 *Tensor) (retVal *Tensor, err error)

func HspmmOut

func HspmmOut(out *Tensor, mat1 *Tensor, mat2 *Tensor) (retVal *Tensor, err error)

func Hstack added in v0.3.0

func Hstack(tensors []Tensor) (retVal *Tensor, err error)

func HstackOut added in v0.3.0

func HstackOut(out *Tensor, tensors []Tensor) (retVal *Tensor, err error)

func Im2colBackward

func Im2colBackward(gradOutput *Tensor, inputSize []int64, kernelSize []int64, dilation []int64, padding []int64, stride []int64) (retVal *Tensor, err error)

func Im2colBackwardOut

func Im2colBackwardOut(gradInput *Tensor, gradOutput *Tensor, inputSize []int64, kernelSize []int64, dilation []int64, padding []int64, stride []int64) (retVal *Tensor, err error)

func IndexSelectBackward added in v0.3.0

func IndexSelectBackward(grad *Tensor, selfSizes []int64, dim int64, index *Tensor) (retVal *Tensor, err error)

func InstanceNorm

func InstanceNorm(input *Tensor, weight *Tensor, bias *Tensor, runningMean *Tensor, runningVar *Tensor, useInputStats bool, momentum float64, eps float64, cudnnEnabled bool) (retVal *Tensor, err error)

func KaiserWindow added in v0.3.0

func KaiserWindow(windowLength int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func KaiserWindow1 added in v0.3.0

func KaiserWindow1(windowLength int64, periodic bool, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func KaiserWindow2 added in v0.3.0

func KaiserWindow2(windowLength int64, periodic bool, beta float64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func LayerNorm

func LayerNorm(input *Tensor, normalizedShape []int64, weight *Tensor, bias *Tensor, eps float64, cudnnEnable bool) (retVal *Tensor, err error)

func Linear

func Linear(input *Tensor, weight *Tensor, bias *Tensor) (retVal *Tensor, err error)

func Linspace

func Linspace(start *Scalar, end *Scalar, steps []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func LinspaceOut

func LinspaceOut(out *Tensor, start *Scalar, end *Scalar, steps []int64) (retVal *Tensor, err error)

func Load

func Load(path string) (*Tensor, error)

Load loads a tensor from a file.

func LoadHwc

func LoadHwc(path string) (*Tensor, error)

LoadHwc returns a tensor of shape [height, width, channels] on success.

func Logspace

func Logspace(start *Scalar, end *Scalar, steps []int64, base float64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func LogspaceOut

func LogspaceOut(out *Tensor, start *Scalar, end *Scalar, steps []int64, base float64) (retVal *Tensor, err error)

func MarginRankingLoss

func MarginRankingLoss(input1 *Tensor, input2 *Tensor, target *Tensor, margin float64, reduction int64) (retVal *Tensor, err error)

func MaskedSelectBackward added in v0.3.0

func MaskedSelectBackward(grad *Tensor, input *Tensor, mask *Tensor) (retVal *Tensor, err error)

func MiopenConvolutionBackwardBias

func MiopenConvolutionBackwardBias(gradOutput *Tensor) (retVal *Tensor, err error)

func MiopenConvolutionBackwardInput

func MiopenConvolutionBackwardInput(selfSize []int64, gradOutput *Tensor, weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool) (retVal *Tensor, err error)

func MiopenConvolutionTransposeBackwardInput

func MiopenConvolutionTransposeBackwardInput(gradOutput *Tensor, weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool) (retVal *Tensor, err error)

func MiopenDepthwiseConvolutionBackwardInput

func MiopenDepthwiseConvolutionBackwardInput(selfSize []int64, gradOutput *Tensor, weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool) (retVal *Tensor, err error)

func MkldnnConvolutionBackwardInput

func MkldnnConvolutionBackwardInput(selfSize []int64, gradOutput *Tensor, weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, biasDefined bool) (retVal *Tensor, err error)

func MkldnnLinear

func MkldnnLinear(input *Tensor, weight *Tensor, bias *Tensor) (retVal *Tensor, err error)

func Must

func Must(ts Tensor, err error) (retVal Tensor)

Must is a helper to unwrap function it wraps. If having error, it will cause panic.

func MustAffineGridGenerator

func MustAffineGridGenerator(theta *Tensor, size []int64, alignCorners bool) (retVal *Tensor)

func MustAffineGridGeneratorBackward

func MustAffineGridGeneratorBackward(grad *Tensor, size []int64, alignCorners bool) (retVal *Tensor)

func MustAlignTensors

func MustAlignTensors(tensors []Tensor, del bool) (retVal []Tensor)

func MustAlphaDropout

func MustAlphaDropout(input *Tensor, p float64, train bool) (retVal *Tensor)

func MustArange

func MustArange(end *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustArange1

func MustArange1(start *Scalar, end *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustArange2

func MustArange2(start *Scalar, end *Scalar, step *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustArangeOut

func MustArangeOut(out *Tensor, end *Scalar) (retVal *Tensor)

func MustArangeOut1

func MustArangeOut1(out *Tensor, start *Scalar, end *Scalar) (retVal *Tensor)

func MustBartlettWindow

func MustBartlettWindow(windowLength int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustBartlettWindow1

func MustBartlettWindow1(windowLength int64, periodic bool, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustBatchNorm

func MustBatchNorm(input *Tensor, weight *Tensor, bias *Tensor, runningMean *Tensor, runningVar *Tensor, training bool, momentum float64, eps float64, cudnnEnabled bool) (retVal *Tensor)

func MustBatchNormBackwardElemt

func MustBatchNormBackwardElemt(gradOut *Tensor, input *Tensor, mean *Tensor, invstd *Tensor, weight *Tensor, meanDy *Tensor, meanDyXmu *Tensor) (retVal *Tensor)

func MustBatchNormElemt

func MustBatchNormElemt(input *Tensor, weight *Tensor, bias *Tensor, mean *Tensor, invstd *Tensor, eps float64) (retVal *Tensor)

func MustBatchNormElemtOut

func MustBatchNormElemtOut(out *Tensor, input *Tensor, weight *Tensor, bias *Tensor, mean *Tensor, invstd *Tensor, eps float64) (retVal *Tensor)

func MustBilinear

func MustBilinear(input1 *Tensor, input2 *Tensor, weight *Tensor, bias *Tensor) (retVal *Tensor)

func MustBinomial added in v0.3.0

func MustBinomial(count *Tensor, prob *Tensor) (retVal *Tensor)

func MustBlackmanWindow

func MustBlackmanWindow(windowLength int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustBlackmanWindow1

func MustBlackmanWindow1(windowLength int64, periodic bool, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustBlockDiag added in v0.3.0

func MustBlockDiag(tensors []Tensor) (retVal *Tensor)

func MustBroadcastTensors

func MustBroadcastTensors(tensors []Tensor, del bool) (retVal []Tensor)

func MustBucketize1 added in v0.3.0

func MustBucketize1(selfScalar *Scalar, boundaries *Tensor, outInt32 bool, right bool) (retVal *Tensor)

func MustCartesianProd

func MustCartesianProd(tensors []Tensor) (retVal *Tensor)

func MustCat

func MustCat(tensors []Tensor, dim int64) (retVal *Tensor)

func MustCatOut

func MustCatOut(out *Tensor, tensors []Tensor, dim int64) (retVal *Tensor)

func MustCdist

func MustCdist(x1 *Tensor, x2 *Tensor, p float64, computeMode []int64) (retVal *Tensor)

func MustChainMatmul

func MustChainMatmul(matrices []Tensor) (retVal *Tensor)

func MustCol2imBackward

func MustCol2imBackward(gradOutput *Tensor, kernelSize []int64, dilation []int64, padding []int64, stride []int64) (retVal *Tensor)

func MustCol2imBackwardOut

func MustCol2imBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, dilation []int64, padding []int64, stride []int64) (retVal *Tensor)

func MustComplex added in v0.3.0

func MustComplex(real *Tensor, imag *Tensor) (retVal *Tensor)

func MustComplexOut added in v0.3.0

func MustComplexOut(out *Tensor, real *Tensor, imag *Tensor) (retVal *Tensor)

func MustConv1d

func MustConv1d(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, groups int64) (retVal *Tensor)

func MustConv2d

func MustConv2d(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, groups int64) (retVal *Tensor)

func MustConv3d

func MustConv3d(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, groups int64) (retVal *Tensor)

func MustConvTranspose1d

func MustConvTranspose1d(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, groups int64, dilation []int64) (retVal *Tensor)

func MustConvTranspose2d

func MustConvTranspose2d(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, groups int64, dilation []int64) (retVal *Tensor)

func MustConvTranspose3d

func MustConvTranspose3d(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, groups int64, dilation []int64) (retVal *Tensor)

func MustConvolution

func MustConvolution(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, transposed bool, outputPadding []int64, groups int64) (retVal *Tensor)

func MustConvolutionOverrideable

func MustConvolutionOverrideable(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, transposed bool, outputPadding []int64, groups int64) (retVal *Tensor)

func MustCosineEmbeddingLoss

func MustCosineEmbeddingLoss(input1 *Tensor, input2 *Tensor, target *Tensor, margin float64, reduction int64) (retVal *Tensor)

func MustCosineSimilarity

func MustCosineSimilarity(x1 *Tensor, x2 *Tensor, dim int64, eps float64) (retVal *Tensor)

func MustCtcLoss

func MustCtcLoss(logProbs *Tensor, targets *Tensor, inputLengths []int64, targetLengths []int64, blank int64, reduction int64, zeroInfinity bool) (retVal *Tensor)

func MustCtcLoss1

func MustCtcLoss1(logProbs *Tensor, targets *Tensor, inputLengths *Tensor, targetLengths *Tensor, blank int64, reduction int64, zeroInfinity bool) (retVal *Tensor)

func MustCudnnAffineGridGenerator

func MustCudnnAffineGridGenerator(theta *Tensor, n int64, c int64, h int64, w int64) (retVal *Tensor)

func MustCudnnAffineGridGeneratorBackward

func MustCudnnAffineGridGeneratorBackward(grad *Tensor, n int64, c int64, h int64, w int64) (retVal *Tensor)

func MustCudnnConvolutionBackwardInput

func MustCudnnConvolutionBackwardInput(selfSize []int64, gradOutput *Tensor, weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, allowTf32 bool) (retVal *Tensor)

func MustCudnnConvolutionTransposeBackwardInput

func MustCudnnConvolutionTransposeBackwardInput(gradOutput *Tensor, weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, allowTf32 bool) (retVal *Tensor)

func MustCummaxminBackward added in v0.3.0

func MustCummaxminBackward(grad *Tensor, input *Tensor, indices *Tensor, dim int64) (retVal *Tensor)

func MustCumprodBackward added in v0.3.0

func MustCumprodBackward(grad *Tensor, input *Tensor, dim int64) (retVal *Tensor)

func MustDiagBackward added in v0.3.0

func MustDiagBackward(grad *Tensor, inputSizes []int64, diagonal int64) (retVal *Tensor)

func MustDiagonalBackward added in v0.3.0

func MustDiagonalBackward(grad *Tensor, inputSizes []int64, offset int64, dim1 int64, dim2 int64) (retVal *Tensor)

func MustDropout

func MustDropout(input *Tensor, p float64, train bool) (retVal *Tensor)

func MustDstack added in v0.3.0

func MustDstack(tensors []Tensor) (retVal *Tensor)

func MustDstackOut added in v0.3.0

func MustDstackOut(out *Tensor, tensors []Tensor) (retVal *Tensor)

func MustEinsum

func MustEinsum(equation string, tensors []Tensor) (retVal *Tensor)

func MustEluBackward

func MustEluBackward(gradOutput *Tensor, alpha *Scalar, scale *Scalar, inputScale *Scalar, output *Tensor) (retVal *Tensor)

func MustEluBackwardOut

func MustEluBackwardOut(gradInput *Tensor, gradOutput *Tensor, alpha *Scalar, scale *Scalar, inputScale *Scalar, output *Tensor) (retVal *Tensor)

func MustEmbedding

func MustEmbedding(weight *Tensor, indices *Tensor, paddingIdx int64, scaleGradByFreq bool, sparse bool) (retVal *Tensor)

func MustEmbeddingBackward

func MustEmbeddingBackward(grad *Tensor, indices *Tensor, numWeights int64, paddingIdx int64, scaleGradByFreq bool, sparse bool) (retVal *Tensor)

func MustEmbeddingDenseBackward

func MustEmbeddingDenseBackward(gradOutput *Tensor, indices *Tensor, numWeights int64, paddingIdx int64, scaleGradByFreq bool) (retVal *Tensor)

func MustEmbeddingSparseBackward

func MustEmbeddingSparseBackward(grad *Tensor, indices *Tensor, numWeights int64, paddingIdx int64, scaleGradByFreq bool) (retVal *Tensor)

func MustEmpty

func MustEmpty(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustEmptyMeta added in v0.3.0

func MustEmptyMeta(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustEmptyOut

func MustEmptyOut(out *Tensor, size []int64) (retVal *Tensor)

func MustEmptyQuantized added in v0.3.0

func MustEmptyQuantized(size []int64, qtensor *Tensor) (retVal *Tensor)

func MustEmptyStrided

func MustEmptyStrided(size []int64, stride []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustEye

func MustEye(n int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustEye1

func MustEye1(n int64, m int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustEyeOut

func MustEyeOut(out *Tensor, n int64) (retVal *Tensor)

func MustEyeOut1

func MustEyeOut1(out *Tensor, n int64, m int64) (retVal *Tensor)

func MustFbgemmLinearFp16Weight

func MustFbgemmLinearFp16Weight(input *Tensor, packedWeight *Tensor, bias *Tensor) (retVal *Tensor)

func MustFbgemmLinearFp16WeightFp32Activation

func MustFbgemmLinearFp16WeightFp32Activation(input *Tensor, packedWeight *Tensor, bias *Tensor) (retVal *Tensor)

func MustFbgemmLinearInt8Weight

func MustFbgemmLinearInt8Weight(input *Tensor, weight *Tensor, packed *Tensor, colOffsets *Tensor, weightScale *Scalar, weightZeroPoint *Scalar, bias *Tensor) (retVal *Tensor)

func MustFbgemmLinearInt8WeightFp32Activation

func MustFbgemmLinearInt8WeightFp32Activation(input *Tensor, weight *Tensor, packed *Tensor, colOffsets *Tensor, weightScale *Scalar, weightZeroPoint *Scalar, bias *Tensor) (retVal *Tensor)

func MustFbgemmPackGemmMatrixFp16

func MustFbgemmPackGemmMatrixFp16(input *Tensor) (retVal *Tensor)

func MustFbgemmPackQuantizedMatrix

func MustFbgemmPackQuantizedMatrix(input *Tensor) (retVal *Tensor)

func MustFbgemmPackQuantizedMatrix1

func MustFbgemmPackQuantizedMatrix1(input *Tensor, k int64, n int64) (retVal *Tensor)

func MustFeatureAlphaDropout

func MustFeatureAlphaDropout(input *Tensor, p float64, train bool) (retVal *Tensor)

func MustFeatureDropout

func MustFeatureDropout(input *Tensor, p float64, train bool) (retVal *Tensor)

func MustFromFile

func MustFromFile(filename string, shared bool, size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustFull

func MustFull(size []int64, fillValue *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustFullOut

func MustFullOut(out *Tensor, size []int64, fillValue *Scalar) (retVal *Tensor)

func MustGridSampler

func MustGridSampler(input *Tensor, grid *Tensor, interpolationMode int64, paddingMode int64, alignCorners bool) (retVal *Tensor)

func MustGridSampler2d

func MustGridSampler2d(input *Tensor, grid *Tensor, interpolationMode int64, paddingMode int64, alignCorners bool) (retVal *Tensor)

func MustGridSampler3d

func MustGridSampler3d(input *Tensor, grid *Tensor, interpolationMode int64, paddingMode int64, alignCorners bool) (retVal *Tensor)

func MustGroupNorm

func MustGroupNorm(input *Tensor, numGroups int64, weight *Tensor, bias *Tensor, eps float64, cudnnEnabled bool) (retVal *Tensor)

func MustGruCell

func MustGruCell(input *Tensor, hx *Tensor, wIh *Tensor, wHh *Tensor, bIh *Tensor, bHh *Tensor) (retVal *Tensor)

func MustHammingWindow

func MustHammingWindow(windowLength int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustHammingWindow1

func MustHammingWindow1(windowLength int64, periodic bool, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustHammingWindow2

func MustHammingWindow2(windowLength int64, periodic bool, alpha float64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustHammingWindow3

func MustHammingWindow3(windowLength int64, periodic bool, alpha float64, beta float64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustHannWindow

func MustHannWindow(windowLength int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustHannWindow1

func MustHannWindow1(windowLength int64, periodic bool, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustHspmm

func MustHspmm(mat1 *Tensor, mat2 *Tensor) (retVal *Tensor)

func MustHspmmOut

func MustHspmmOut(out *Tensor, mat1 *Tensor, mat2 *Tensor) (retVal *Tensor)

func MustHstack added in v0.3.0

func MustHstack(tensors []Tensor) (retVal *Tensor)

func MustHstackOut added in v0.3.0

func MustHstackOut(out *Tensor, tensors []Tensor) (retVal *Tensor)

func MustIm2colBackward

func MustIm2colBackward(gradOutput *Tensor, inputSize []int64, kernelSize []int64, dilation []int64, padding []int64, stride []int64) (retVal *Tensor)

func MustIm2colBackwardOut

func MustIm2colBackwardOut(gradInput *Tensor, gradOutput *Tensor, inputSize []int64, kernelSize []int64, dilation []int64, padding []int64, stride []int64) (retVal *Tensor)

func MustIndexSelectBackward added in v0.3.0

func MustIndexSelectBackward(grad *Tensor, selfSizes []int64, dim int64, index *Tensor) (retVal *Tensor)

func MustInstanceNorm

func MustInstanceNorm(input *Tensor, weight *Tensor, bias *Tensor, runningMean *Tensor, runningVar *Tensor, useInputStats bool, momentum float64, eps float64, cudnnEnabled bool) (retVal *Tensor)

func MustKaiserWindow added in v0.3.0

func MustKaiserWindow(windowLength int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustKaiserWindow1 added in v0.3.0

func MustKaiserWindow1(windowLength int64, periodic bool, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustKaiserWindow2 added in v0.3.0

func MustKaiserWindow2(windowLength int64, periodic bool, beta float64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustLayerNorm

func MustLayerNorm(input *Tensor, normalizedShape []int64, weight *Tensor, bias *Tensor, eps float64, cudnnEnable bool) (retVal *Tensor)

func MustLinear

func MustLinear(input *Tensor, weight *Tensor, bias *Tensor) (retVal *Tensor)

func MustLinspace

func MustLinspace(start *Scalar, end *Scalar, steps []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustLinspaceOut

func MustLinspaceOut(out *Tensor, start *Scalar, end *Scalar, steps []int64) (retVal *Tensor)

func MustLoad

func MustLoad(path string) *Tensor

MustLoad loads a tensor to a file. It will panic if error

func MustLogspace

func MustLogspace(start *Scalar, end *Scalar, steps []int64, base float64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustLogspaceOut

func MustLogspaceOut(out *Tensor, start *Scalar, end *Scalar, steps []int64, base float64) (retVal *Tensor)

func MustMarginRankingLoss

func MustMarginRankingLoss(input1 *Tensor, input2 *Tensor, target *Tensor, margin float64, reduction int64) (retVal *Tensor)

func MustMaskedSelectBackward added in v0.3.0

func MustMaskedSelectBackward(grad *Tensor, input *Tensor, mask *Tensor) (retVal *Tensor)

func MustMiopenConvolutionBackwardBias

func MustMiopenConvolutionBackwardBias(gradOutput *Tensor) (retVal *Tensor)

func MustMiopenConvolutionBackwardInput

func MustMiopenConvolutionBackwardInput(selfSize []int64, gradOutput *Tensor, weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool) (retVal *Tensor)

func MustMiopenConvolutionTransposeBackwardInput

func MustMiopenConvolutionTransposeBackwardInput(gradOutput *Tensor, weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool) (retVal *Tensor)

func MustMiopenDepthwiseConvolutionBackwardInput

func MustMiopenDepthwiseConvolutionBackwardInput(selfSize []int64, gradOutput *Tensor, weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool) (retVal *Tensor)

func MustMkldnnConvolutionBackwardInput

func MustMkldnnConvolutionBackwardInput(selfSize []int64, gradOutput *Tensor, weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, biasDefined bool) (retVal *Tensor)

func MustMkldnnLinear

func MustMkldnnLinear(input *Tensor, weight *Tensor, bias *Tensor) (retVal *Tensor)

func MustNormExceptDim

func MustNormExceptDim(v *Tensor, pow int64, dim int64) (retVal *Tensor)

func MustNormalOut

func MustNormalOut(out *Tensor, mean *Tensor, std float64) (retVal *Tensor)

func MustNormalOut1

func MustNormalOut1(out *Tensor, mean float64, std *Tensor) (retVal *Tensor)

func MustNormalOut2

func MustNormalOut2(out *Tensor, mean *Tensor, std *Tensor) (retVal *Tensor)

func MustNormalOut3

func MustNormalOut3(out *Tensor, mean float64, std float64, size []int64) (retVal *Tensor)

func MustOfDataSize added in v0.3.3

func MustOfDataSize(data []byte, size []int64, dtype gotch.DType) *Tensor

MustOfDataSize create Tensor from input byte data and specified shape and dtype or panic if error

func MustOfSlice

func MustOfSlice(data interface{}) *Tensor

MustOfSlice create a tensor from slice of data. It will be panic if error.

func MustOnes

func MustOnes(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustOnesOut

func MustOnesOut(out *Tensor, size []int64) (retVal *Tensor)

func MustPairwiseDistance

func MustPairwiseDistance(x1 *Tensor, x2 *Tensor, p float64, eps float64, keepdim bool) (retVal *Tensor)

func MustPoissonNllLoss

func MustPoissonNllLoss(input *Tensor, target *Tensor, logInput bool, full bool, eps float64, reduction int64) (retVal *Tensor)

func MustPolar added in v0.3.0

func MustPolar(abs *Tensor, angle *Tensor) (retVal *Tensor)

func MustPolarOut added in v0.3.0

func MustPolarOut(out *Tensor, abs *Tensor, angle *Tensor) (retVal *Tensor)

func MustPow2

func MustPow2(selfScalar *Scalar, exponent *Tensor) (retVal *Tensor)

func MustPowOut2

func MustPowOut2(out *Tensor, selfScalar *Scalar, exponent *Tensor) (retVal *Tensor)

func MustQuantizedBatchNorm

func MustQuantizedBatchNorm(input *Tensor, weight *Tensor, bias *Tensor, mean *Tensor, vari *Tensor, eps float64, outputScale float64, outputZeroPoint int64) (retVal *Tensor)

func MustQuantizedGruCell

func MustQuantizedGruCell(input *Tensor, hx *Tensor, wIh *Tensor, wHh *Tensor, bIh *Tensor, bHh *Tensor, packedIh *Tensor, packedHh *Tensor, colOffsetsIh *Tensor, colOffsetsHh *Tensor, scaleIh *Scalar, scaleHh *Scalar, zeroPointIh *Scalar, zeroPointHh *Scalar) (retVal *Tensor)

func MustQuantizedRnnReluCell

func MustQuantizedRnnReluCell(input *Tensor, hx *Tensor, wIh *Tensor, wHh *Tensor, bIh *Tensor, bHh *Tensor, packedIh *Tensor, packedHh *Tensor, colOffsetsIh *Tensor, colOffsetsHh *Tensor, scaleIh *Scalar, scaleHh *Scalar, zeroPointIh *Scalar, zeroPointHh *Scalar) (retVal *Tensor)

func MustQuantizedRnnTanhCell

func MustQuantizedRnnTanhCell(input *Tensor, hx *Tensor, wIh *Tensor, wHh *Tensor, bIh *Tensor, bHh *Tensor, packedIh *Tensor, packedHh *Tensor, colOffsetsIh *Tensor, colOffsetsHh *Tensor, scaleIh *Scalar, scaleHh *Scalar, zeroPointIh *Scalar, zeroPointHh *Scalar) (retVal *Tensor)

func MustRand

func MustRand(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustRandOut

func MustRandOut(out *Tensor, size []int64) (retVal *Tensor)

func MustRandint

func MustRandint(high int64, size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustRandint1

func MustRandint1(low int64, high int64, size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustRandintOut

func MustRandintOut(out *Tensor, high int64, size []int64) (retVal *Tensor)

func MustRandintOut1

func MustRandintOut1(out *Tensor, low int64, high int64, size []int64) (retVal *Tensor)

func MustRandn

func MustRandn(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustRandnOut

func MustRandnOut(out *Tensor, size []int64) (retVal *Tensor)

func MustRandperm

func MustRandperm(n int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustRandpermOut

func MustRandpermOut(out *Tensor, n int64) (retVal *Tensor)

func MustRange

func MustRange(start *Scalar, end *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustRange1

func MustRange1(start *Scalar, end *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustRangeOut

func MustRangeOut(out *Tensor, start *Scalar, end *Scalar) (retVal *Tensor)

func MustRepeatInterleave

func MustRepeatInterleave(repeats *Tensor) (retVal *Tensor)

func MustRnnReluCell

func MustRnnReluCell(input *Tensor, hx *Tensor, wIh *Tensor, wHh *Tensor, bIh *Tensor, bHh *Tensor) (retVal *Tensor)

func MustRnnTanhCell

func MustRnnTanhCell(input *Tensor, hx *Tensor, wIh *Tensor, wHh *Tensor, bIh *Tensor, bHh *Tensor) (retVal *Tensor)

func MustScalarTensor

func MustScalarTensor(s *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustSearchsorted1 added in v0.3.0

func MustSearchsorted1(sortedSequence *Tensor, selfScalar *Scalar, outInt32 bool, right bool) (retVal *Tensor)

func MustSelectBackward added in v0.3.0

func MustSelectBackward(grad *Tensor, inputSizes []int64, dim int64, index int64) (retVal *Tensor)

func MustSigmoidBackward

func MustSigmoidBackward(gradOutput *Tensor, output *Tensor) (retVal *Tensor)

func MustSigmoidBackwardOut

func MustSigmoidBackwardOut(gradInput *Tensor, gradOutput *Tensor, output *Tensor) (retVal *Tensor)

func MustSliceBackward added in v0.3.0

func MustSliceBackward(grad *Tensor, inputSizes []int64, dim int64, start int64, end int64, step int64) (retVal *Tensor)

func MustSparseCooTensor

func MustSparseCooTensor(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustSparseCooTensor1

func MustSparseCooTensor1(indices *Tensor, values *Tensor, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustSparseCooTensor2

func MustSparseCooTensor2(indices *Tensor, values *Tensor, size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustStack

func MustStack(tensors []Tensor, dim int64) (retVal *Tensor)

func MustStackOut

func MustStackOut(out *Tensor, tensors []Tensor, dim int64) (retVal *Tensor)

func MustTakeBackward added in v0.3.0

func MustTakeBackward(grad *Tensor, input *Tensor, index *Tensor) (retVal *Tensor)

func MustTanhBackward

func MustTanhBackward(gradOutput *Tensor, output *Tensor) (retVal *Tensor)

func MustTanhBackwardOut

func MustTanhBackwardOut(gradInput *Tensor, gradOutput *Tensor, output *Tensor) (retVal *Tensor)

func MustToDenseBackward

func MustToDenseBackward(grad *Tensor, input *Tensor) (retVal *Tensor)

func MustToMkldnnBackward

func MustToMkldnnBackward(grad *Tensor, input *Tensor) (retVal *Tensor)

func MustTraceBackward added in v0.3.0

func MustTraceBackward(grad *Tensor, sizes []int64) (retVal *Tensor)

func MustTrapz

func MustTrapz(y *Tensor, x *Tensor, dim int64) (retVal *Tensor)

func MustTrapz1

func MustTrapz1(y *Tensor, dx float64, dim int64) (retVal *Tensor)

func MustTrilIndices

func MustTrilIndices(row int64, col int64, offset int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustTripletMarginLoss

func MustTripletMarginLoss(anchor *Tensor, positive *Tensor, negative *Tensor, margin float64, p float64, eps float64, swap bool, reduction int64) (retVal *Tensor)

func MustTriuIndices

func MustTriuIndices(row int64, col int64, offset int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustUnfoldBackward added in v0.3.0

func MustUnfoldBackward(gradIn *Tensor, inputSizes []int64, dim int64, size int64, step int64) (retVal *Tensor)

func MustUpsampleBicubic2dBackward

func MustUpsampleBicubic2dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64) (retVal *Tensor)

func MustUpsampleBicubic2dBackwardOut

func MustUpsampleBicubic2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64) (retVal *Tensor)

func MustUpsampleBilinear2dBackward

func MustUpsampleBilinear2dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64) (retVal *Tensor)

func MustUpsampleBilinear2dBackwardOut

func MustUpsampleBilinear2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64) (retVal *Tensor)

func MustUpsampleLinear1dBackward

func MustUpsampleLinear1dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scales []float64) (retVal *Tensor)

func MustUpsampleLinear1dBackwardOut

func MustUpsampleLinear1dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scales []float64) (retVal *Tensor)

func MustUpsampleNearest1dBackward

func MustUpsampleNearest1dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, scales []float64) (retVal *Tensor)

func MustUpsampleNearest1dBackwardOut

func MustUpsampleNearest1dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, scales []float64) (retVal *Tensor)

func MustUpsampleNearest2dBackward

func MustUpsampleNearest2dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, scalesH []float64, scalesW []float64) (retVal *Tensor)

func MustUpsampleNearest2dBackwardOut

func MustUpsampleNearest2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, scalesH []float64, scalesW []float64) (retVal *Tensor)

func MustUpsampleNearest3dBackward

func MustUpsampleNearest3dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, scalesD []float64, scalesH []float64, scalesW []float64) (retVal *Tensor)

func MustUpsampleNearest3dBackwardOut

func MustUpsampleNearest3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, scalesD []float64, scalesH []float64, scalesW []float64) (retVal *Tensor)

func MustUpsampleTrilinear3dBackward

func MustUpsampleTrilinear3dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scalesD []float64, scalesH []float64, scalesW []float64) (retVal *Tensor)

func MustUpsampleTrilinear3dBackwardOut

func MustUpsampleTrilinear3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scalesD []float64, scalesH []float64, scalesW []float64) (retVal *Tensor)

func MustValueSelectingReductionBackward added in v0.3.0

func MustValueSelectingReductionBackward(grad *Tensor, dim int64, indices *Tensor, sizes []int64, keepdim bool) (retVal *Tensor)

func MustVander added in v0.3.0

func MustVander(x *Tensor, n []int64, increasing bool) (retVal *Tensor)

func MustVstack added in v0.3.0

func MustVstack(tensors []Tensor) (retVal *Tensor)

func MustVstackOut added in v0.3.0

func MustVstackOut(out *Tensor, tensors []Tensor) (retVal *Tensor)

func MustWhere

func MustWhere(condition Tensor, del bool) (retVal []Tensor)

func MustWhere2 added in v0.3.0

func MustWhere2(condition *Tensor, selfScalar *Scalar, other *Tensor) (retVal *Tensor)

func MustWhere4 added in v0.3.0

func MustWhere4(condition *Tensor, selfScalar *Scalar, other *Scalar) (retVal *Tensor)

func MustZeros

func MustZeros(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func MustZerosOut

func MustZerosOut(out *Tensor, size []int64) (retVal *Tensor)

func Must_AmpUpdateScale

func Must_AmpUpdateScale(growthTracker *Tensor, currentScale *Tensor, foundInf *Tensor, scaleGrowthFactor float64, scaleBackoffFactor float64, growthInterval int64) (retVal *Tensor)

func Must_Cat

func Must_Cat(tensors []Tensor, dim int64) (retVal *Tensor)

func Must_CatOut

func Must_CatOut(out *Tensor, tensors []Tensor, dim int64) (retVal *Tensor)

func Must_CdistBackward

func Must_CdistBackward(grad *Tensor, x1 *Tensor, x2 *Tensor, p float64, cdist *Tensor) (retVal *Tensor)

func Must_ComputeLinearCombination added in v0.3.0

func Must_ComputeLinearCombination(input *Tensor, coefficients *Tensor) (retVal *Tensor)

func Must_ComputeLinearCombinationOut added in v0.3.0

func Must_ComputeLinearCombinationOut(out *Tensor, input *Tensor, coefficients *Tensor) (retVal *Tensor)

func Must_Convolution

func Must_Convolution(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, transposed bool, outputPadding []int64, groups int64, benchmark bool, deterministic bool, cudnnEnabled bool) (retVal *Tensor)

func Must_Convolution1 added in v0.3.0

func Must_Convolution1(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, transposed bool, outputPadding []int64, groups int64, benchmark bool, deterministic bool, cudnnEnabled bool, allowTf32 bool) (retVal *Tensor)

func Must_ConvolutionNogroup

func Must_ConvolutionNogroup(input *Tensor, weight *Tensor, bias *Tensor, stride []int64, padding []int64, dilation []int64, transposed bool, outputPadding []int64) (retVal *Tensor)

func Must_CtcLossBackward

func Must_CtcLossBackward(grad *Tensor, logProbs *Tensor, targets *Tensor, inputLengths []int64, targetLengths []int64, negLogLikelihood *Tensor, logAlpha *Tensor, blank int64, zeroInfinity bool) (retVal *Tensor)

func Must_CudnnInitDropoutState

func Must_CudnnInitDropoutState(dropout float64, train bool, dropoutSeed int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func Must_CudnnRnnFlattenWeight

func Must_CudnnRnnFlattenWeight(weightArr []Tensor, weightStride0 int64, inputSize int64, mode int64, hiddenSize int64, numLayers int64, batchFirst bool, bidirectional bool) (retVal *Tensor)

func Must_DimArange

func Must_DimArange(like *Tensor, dim int64) (retVal *Tensor)

func Must_DirichletGrad

func Must_DirichletGrad(x *Tensor, alpha *Tensor, total *Tensor) (retVal *Tensor)

func Must_EmbeddingBagBackward

func Must_EmbeddingBagBackward(grad *Tensor, indices *Tensor, offsets *Tensor, offset2bag *Tensor, bagSize *Tensor, maximumIndices *Tensor, numWeights int64, scaleGradByFreq bool, mode int64, sparse bool, perSampleWeights *Tensor) (retVal *Tensor)

func Must_EmbeddingBagDenseBackward

func Must_EmbeddingBagDenseBackward(grad *Tensor, indices *Tensor, offsets *Tensor, offset2bag *Tensor, bagSize *Tensor, maximumIndices *Tensor, numWeights int64, scaleGradByFreq bool, mode int64, perSampleWeights *Tensor) (retVal *Tensor)

func Must_EmbeddingBagPerSampleWeightsBackward

func Must_EmbeddingBagPerSampleWeightsBackward(grad *Tensor, weight *Tensor, indices *Tensor, offsets *Tensor, offset2bag *Tensor, mode int64) (retVal *Tensor)

func Must_EmbeddingBagSparseBackward

func Must_EmbeddingBagSparseBackward(grad *Tensor, indices *Tensor, offsets *Tensor, offset2bag *Tensor, bagSize *Tensor, numWeights int64, scaleGradByFreq bool, mode int64, perSampleWeights *Tensor) (retVal *Tensor)

func Must_EmptyAffineQuantized

func Must_EmptyAffineQuantized(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device, scale float64, zeroPoint int64) (retVal *Tensor)

func Must_EmptyPerChannelAffineQuantized

func Must_EmptyPerChannelAffineQuantized(size []int64, scales *Tensor, zeroPoints *Tensor, axis int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func Must_EuclideanDist added in v0.3.0

func Must_EuclideanDist(x1 *Tensor, x2 *Tensor) (retVal *Tensor)

func Must_GridSampler2dCpuFallback added in v0.3.0

func Must_GridSampler2dCpuFallback(input *Tensor, grid *Tensor, interpolationMode int64, paddingMode int64, alignCorners bool) (retVal *Tensor)

func Must_MultinomialAliasDraw

func Must_MultinomialAliasDraw(j *Tensor, q *Tensor, numSamples int64) (retVal *Tensor)

func Must_NnpackSpatialConvolution

func Must_NnpackSpatialConvolution(input *Tensor, weight *Tensor, bias *Tensor, padding []int64, stride []int64) (retVal *Tensor)

func Must_NnpackSpatialConvolutionBackwardInput

func Must_NnpackSpatialConvolutionBackwardInput(input *Tensor, gradOutput *Tensor, weight *Tensor, padding []int64) (retVal *Tensor)

func Must_NnpackSpatialConvolutionBackwardWeight

func Must_NnpackSpatialConvolutionBackwardWeight(input *Tensor, weightsize []int64, gradOutput *Tensor, padding []int64) (retVal *Tensor)

func Must_PackPaddedSequenceBackward

func Must_PackPaddedSequenceBackward(grad *Tensor, inputSize []int64, batchSizes *Tensor, batchFirst bool) (retVal *Tensor)

func Must_SaturateWeightToFp16 added in v0.3.0

func Must_SaturateWeightToFp16(weight *Tensor) (retVal *Tensor)

func Must_SparseCooTensorUnsafe

func Must_SparseCooTensorUnsafe(indices *Tensor, values *Tensor, size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func Must_SparseCooTensorWithDims

func Must_SparseCooTensorWithDims(sparseDim int64, denseDim int64, size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func Must_SparseCooTensorWithDimsAndTensors

func Must_SparseCooTensorWithDimsAndTensors(sparseDim int64, denseDim int64, size []int64, indices *Tensor, values *Tensor, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor)

func Must_SparseMm

func Must_SparseMm(sparse *Tensor, dense *Tensor) (retVal *Tensor)

func Must_TestOptionalFilledIntlist added in v0.3.0

func Must_TestOptionalFilledIntlist(values *Tensor, addends []int64) (retVal *Tensor)

func Must_TestOptionalIntlist added in v0.3.0

func Must_TestOptionalIntlist(values *Tensor, addends []int64) (retVal *Tensor)

func Must_Trilinear

func Must_Trilinear(i1 *Tensor, i2 *Tensor, i3 *Tensor, expand1 []int64, expand2 []int64, expand3 []int64, sumdim []int64, unrollDim int64) (retVal *Tensor)

func Must_WeightNorm

func Must_WeightNorm(v *Tensor, g *Tensor, dim int64) (retVal *Tensor)

func NewTensor

func NewTensor() *Tensor

NewTensor creates a new tensor

func NewTensorFromData

func NewTensorFromData(data interface{}, shape []int64) (*Tensor, error)

NewTensorFromData creates tensor from given data and shape

func NormExceptDim

func NormExceptDim(v *Tensor, pow int64, dim int64) (retVal *Tensor, err error)

func NormalOut

func NormalOut(out *Tensor, mean *Tensor, std float64) (retVal *Tensor, err error)

func NormalOut1

func NormalOut1(out *Tensor, mean float64, std *Tensor) (retVal *Tensor, err error)

func NormalOut2

func NormalOut2(out *Tensor, mean *Tensor, std *Tensor) (retVal *Tensor, err error)

func NormalOut3

func NormalOut3(out *Tensor, mean float64, std float64, size []int64) (retVal *Tensor, err error)

func OfDataSize added in v0.3.3

func OfDataSize(data []byte, shape []int64, dtype gotch.DType) (*Tensor, error)

OfDataSize creates Tensor from input byte data, shape and dtype.

func OfSlice

func OfSlice(data interface{}) (*Tensor, error)

OfSlice creates tensor from a slice data

func Ones

func Ones(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func OnesOut

func OnesOut(out *Tensor, size []int64) (retVal *Tensor, err error)

func PairwiseDistance

func PairwiseDistance(x1 *Tensor, x2 *Tensor, p float64, eps float64, keepdim bool) (retVal *Tensor, err error)

func PoissonNllLoss

func PoissonNllLoss(input *Tensor, target *Tensor, logInput bool, full bool, eps float64, reduction int64) (retVal *Tensor, err error)

func Polar added in v0.3.0

func Polar(abs *Tensor, angle *Tensor) (retVal *Tensor, err error)

func PolarOut added in v0.3.0

func PolarOut(out *Tensor, abs *Tensor, angle *Tensor) (retVal *Tensor, err error)

func Pow2

func Pow2(selfScalar *Scalar, exponent *Tensor) (retVal *Tensor, err error)

func PowOut2

func PowOut2(out *Tensor, selfScalar *Scalar, exponent *Tensor) (retVal *Tensor, err error)

func QuantizedBatchNorm

func QuantizedBatchNorm(input *Tensor, weight *Tensor, bias *Tensor, mean *Tensor, vari *Tensor, eps float64, outputScale float64, outputZeroPoint int64) (retVal *Tensor, err error)

func QuantizedGruCell

func QuantizedGruCell(input *Tensor, hx *Tensor, wIh *Tensor, wHh *Tensor, bIh *Tensor, bHh *Tensor, packedIh *Tensor, packedHh *Tensor, colOffsetsIh *Tensor, colOffsetsHh *Tensor, scaleIh *Scalar, scaleHh *Scalar, zeroPointIh *Scalar, zeroPointHh *Scalar) (retVal *Tensor, err error)

func QuantizedRnnReluCell

func QuantizedRnnReluCell(input *Tensor, hx *Tensor, wIh *Tensor, wHh *Tensor, bIh *Tensor, bHh *Tensor, packedIh *Tensor, packedHh *Tensor, colOffsetsIh *Tensor, colOffsetsHh *Tensor, scaleIh *Scalar, scaleHh *Scalar, zeroPointIh *Scalar, zeroPointHh *Scalar) (retVal *Tensor, err error)

func QuantizedRnnTanhCell

func QuantizedRnnTanhCell(input *Tensor, hx *Tensor, wIh *Tensor, wHh *Tensor, bIh *Tensor, bHh *Tensor, packedIh *Tensor, packedHh *Tensor, colOffsetsIh *Tensor, colOffsetsHh *Tensor, scaleIh *Scalar, scaleHh *Scalar, zeroPointIh *Scalar, zeroPointHh *Scalar) (retVal *Tensor, err error)

func Rand

func Rand(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func RandOut

func RandOut(out *Tensor, size []int64) (retVal *Tensor, err error)

func Randint

func Randint(high int64, size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func Randint1

func Randint1(low int64, high int64, size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func RandintOut

func RandintOut(out *Tensor, high int64, size []int64) (retVal *Tensor, err error)

func RandintOut1

func RandintOut1(out *Tensor, low int64, high int64, size []int64) (retVal *Tensor, err error)

func Randn

func Randn(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func RandnOut

func RandnOut(out *Tensor, size []int64) (retVal *Tensor, err error)

func Randperm

func Randperm(n int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func RandpermOut

func RandpermOut(out *Tensor, n int64) (retVal *Tensor, err error)

func Range

func Range(start *Scalar, end *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func Range1

func Range1(start *Scalar, end *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func RangeOut

func RangeOut(out *Tensor, start *Scalar, end *Scalar) (retVal *Tensor, err error)

func ReadNpy added in v0.3.3

func ReadNpy(filepath string) (*Tensor, error)

ReadNpy reads a .npy file and returns the stored tensor.

func RepeatInterleave

func RepeatInterleave(repeats *Tensor) (retVal *Tensor, err error)

func ResizeHwc

func ResizeHwc(ts *Tensor, outWidth, outHeight int64) (*Tensor, error)

ResizeHwc expects a tensor of shape [height, width, channels]. On success returns a tensor of shape [height, width, channels].

func RnnReluCell

func RnnReluCell(input *Tensor, hx *Tensor, wIh *Tensor, wHh *Tensor, bIh *Tensor, bHh *Tensor) (retVal *Tensor, err error)

func RnnTanhCell

func RnnTanhCell(input *Tensor, hx *Tensor, wIh *Tensor, wHh *Tensor, bIh *Tensor, bHh *Tensor) (retVal *Tensor, err error)

func RunBackward

func RunBackward(tensors []Tensor, inputs []Tensor, keepGraphB bool, createGraphB bool) ([]Tensor, error)

RunBackward runs the backward ...

func ScalarTensor

func ScalarTensor(s *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func Searchsorted1 added in v0.3.0

func Searchsorted1(sortedSequence *Tensor, selfScalar *Scalar, outInt32 bool, right bool) (retVal *Tensor, err error)

func SelectBackward added in v0.3.0

func SelectBackward(grad *Tensor, inputSizes []int64, dim int64, index int64) (retVal *Tensor, err error)

func SigmoidBackward

func SigmoidBackward(gradOutput *Tensor, output *Tensor) (retVal *Tensor, err error)

func SigmoidBackwardOut

func SigmoidBackwardOut(gradInput *Tensor, gradOutput *Tensor, output *Tensor) (retVal *Tensor, err error)

func SliceBackward added in v0.3.0

func SliceBackward(grad *Tensor, inputSizes []int64, dim int64, start int64, end int64, step int64) (retVal *Tensor, err error)

func SparseCooTensor

func SparseCooTensor(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func SparseCooTensor1

func SparseCooTensor1(indices *Tensor, values *Tensor, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func SparseCooTensor2

func SparseCooTensor2(indices *Tensor, values *Tensor, size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func Stack

func Stack(tensors []Tensor, dim int64) (retVal *Tensor, err error)

func StackOut

func StackOut(out *Tensor, tensors []Tensor, dim int64) (retVal *Tensor, err error)

func TakeBackward added in v0.3.0

func TakeBackward(grad *Tensor, input *Tensor, index *Tensor) (retVal *Tensor, err error)

func TanhBackward

func TanhBackward(gradOutput *Tensor, output *Tensor) (retVal *Tensor, err error)

func TanhBackwardOut

func TanhBackwardOut(gradInput *Tensor, gradOutput *Tensor, output *Tensor) (retVal *Tensor, err error)

func TensorFrom

func TensorFrom(data interface{}) *Tensor

TensorFrom create a tensor from slice of data. It will be panic if error.

func ToDenseBackward

func ToDenseBackward(grad *Tensor, input *Tensor) (retVal *Tensor, err error)

func ToMkldnnBackward

func ToMkldnnBackward(grad *Tensor, input *Tensor) (retVal *Tensor, err error)

func TraceBackward added in v0.3.0

func TraceBackward(grad *Tensor, sizes []int64) (retVal *Tensor, err error)

func Trapz

func Trapz(y *Tensor, x *Tensor, dim int64) (retVal *Tensor, err error)

func Trapz1

func Trapz1(y *Tensor, dx float64, dim int64) (retVal *Tensor, err error)

func TrilIndices

func TrilIndices(row int64, col int64, offset int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func TripletMarginLoss

func TripletMarginLoss(anchor *Tensor, positive *Tensor, negative *Tensor, margin float64, p float64, eps float64, swap bool, reduction int64) (retVal *Tensor, err error)

func TriuIndices

func TriuIndices(row int64, col int64, offset int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func UnfoldBackward added in v0.3.0

func UnfoldBackward(gradIn *Tensor, inputSizes []int64, dim int64, size int64, step int64) (retVal *Tensor, err error)

func UpsampleBicubic2dBackward

func UpsampleBicubic2dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64) (retVal *Tensor, err error)

func UpsampleBicubic2dBackwardOut

func UpsampleBicubic2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64) (retVal *Tensor, err error)

func UpsampleBilinear2dBackward

func UpsampleBilinear2dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64) (retVal *Tensor, err error)

func UpsampleBilinear2dBackwardOut

func UpsampleBilinear2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64) (retVal *Tensor, err error)

func UpsampleLinear1dBackward

func UpsampleLinear1dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scales []float64) (retVal *Tensor, err error)

func UpsampleLinear1dBackwardOut

func UpsampleLinear1dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scales []float64) (retVal *Tensor, err error)

func UpsampleNearest1dBackward

func UpsampleNearest1dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, scales []float64) (retVal *Tensor, err error)

func UpsampleNearest1dBackwardOut

func UpsampleNearest1dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, scales []float64) (retVal *Tensor, err error)

func UpsampleNearest2dBackward

func UpsampleNearest2dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, scalesH []float64, scalesW []float64) (retVal *Tensor, err error)

func UpsampleNearest2dBackwardOut

func UpsampleNearest2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, scalesH []float64, scalesW []float64) (retVal *Tensor, err error)

func UpsampleNearest3dBackward

func UpsampleNearest3dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, scalesD []float64, scalesH []float64, scalesW []float64) (retVal *Tensor, err error)

func UpsampleNearest3dBackwardOut

func UpsampleNearest3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, scalesD []float64, scalesH []float64, scalesW []float64) (retVal *Tensor, err error)

func UpsampleTrilinear3dBackward

func UpsampleTrilinear3dBackward(gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scalesD []float64, scalesH []float64, scalesW []float64) (retVal *Tensor, err error)

func UpsampleTrilinear3dBackwardOut

func UpsampleTrilinear3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, outputSize []int64, inputSize []int64, alignCorners bool, scalesD []float64, scalesH []float64, scalesW []float64) (retVal *Tensor, err error)

func ValueSelectingReductionBackward added in v0.3.0

func ValueSelectingReductionBackward(grad *Tensor, dim int64, indices *Tensor, sizes []int64, keepdim bool) (retVal *Tensor, err error)

func Vander added in v0.3.0

func Vander(x *Tensor, n []int64, increasing bool) (retVal *Tensor, err error)

func Vstack added in v0.3.0

func Vstack(tensors []Tensor) (retVal *Tensor, err error)

func VstackOut added in v0.3.0

func VstackOut(out *Tensor, tensors []Tensor) (retVal *Tensor, err error)

func Where

func Where(condition Tensor) (retVal []Tensor, err error)

tensor *atg_where(tensor condition);

func Where2 added in v0.3.0

func Where2(condition *Tensor, selfScalar *Scalar, other *Tensor) (retVal *Tensor, err error)

func Where4 added in v0.3.0

func Where4(condition *Tensor, selfScalar *Scalar, other *Scalar) (retVal *Tensor, err error)

func Zeros

func Zeros(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device) (retVal *Tensor, err error)

func ZerosOut

func ZerosOut(out *Tensor, size []int64) (retVal *Tensor, err error)

func (*Tensor) Abs

func (ts *Tensor) Abs(del bool) (retVal *Tensor, err error)

func (*Tensor) AbsOut

func (ts *Tensor) AbsOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Abs_

func (ts *Tensor) Abs_() (err error)

func (*Tensor) Absolute added in v0.3.0

func (ts *Tensor) Absolute(del bool) (retVal *Tensor, err error)

func (*Tensor) AbsoluteOut added in v0.3.0

func (ts *Tensor) AbsoluteOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Absolute_ added in v0.3.0

func (ts *Tensor) Absolute_() (err error)

func (*Tensor) AccuracyForLogits

func (ts *Tensor) AccuracyForLogits(targets *Tensor) (retVal *Tensor)

AccuracyForLogits returns the average accuracy for some given logits assuming that targets represent ground-truth.

func (*Tensor) Acos

func (ts *Tensor) Acos(del bool) (retVal *Tensor, err error)

func (*Tensor) AcosOut

func (ts *Tensor) AcosOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Acos_

func (ts *Tensor) Acos_() (err error)

func (*Tensor) Acosh added in v0.3.0

func (ts *Tensor) Acosh(del bool) (retVal *Tensor, err error)

func (*Tensor) AcoshOut added in v0.3.0

func (ts *Tensor) AcoshOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Acosh_ added in v0.3.0

func (ts *Tensor) Acosh_() (err error)

func (*Tensor) AdaptiveAvgPool1d

func (ts *Tensor) AdaptiveAvgPool1d(outputSize []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AdaptiveAvgPool2d

func (ts *Tensor) AdaptiveAvgPool2d(outputSize []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AdaptiveAvgPool2dOut

func (ts *Tensor) AdaptiveAvgPool2dOut(out *Tensor, outputSize []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AdaptiveAvgPool3d

func (ts *Tensor) AdaptiveAvgPool3d(outputSize []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AdaptiveAvgPool3dBackward

func (ts *Tensor) AdaptiveAvgPool3dBackward(gradOutput *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) AdaptiveAvgPool3dBackwardOut

func (ts *Tensor) AdaptiveAvgPool3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) AdaptiveAvgPool3dOut

func (ts *Tensor) AdaptiveAvgPool3dOut(out *Tensor, outputSize []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AdaptiveMaxPool2dBackward

func (ts *Tensor) AdaptiveMaxPool2dBackward(gradOutput *Tensor, indices *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) AdaptiveMaxPool2dBackwardOut

func (ts *Tensor) AdaptiveMaxPool2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, indices *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) AdaptiveMaxPool3dBackward

func (ts *Tensor) AdaptiveMaxPool3dBackward(gradOutput *Tensor, indices *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) AdaptiveMaxPool3dBackwardOut

func (ts *Tensor) AdaptiveMaxPool3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, indices *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Add

func (ts *Tensor) Add(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Add1

func (ts *Tensor) Add1(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Add1_

func (ts *Tensor) Add1_(other *Scalar) (err error)
Example
package main

import (
	"fmt"

	"github.com/sugarme/gotch"
	ts "github.com/sugarme/gotch/tensor"
)

func main() {
	// In-place operation
	ts3 := ts.MustOnes([]int64{2, 3}, gotch.Float, gotch.CPU)
	fmt.Println("Before:")
	ts3.Print()
	ts3.MustAdd1_(ts.FloatScalar(2.0))
	fmt.Printf("After (ts3 + 2.0): \n")
	ts3.Print()
	ts3.MustDrop()

	//Before:
	// 1  1  1
	// 1  1  1
	//[ CPUFloatType{2,3} ]
	//After (ts3 + 2.0):
	// 3  3  3
	// 3  3  3
	//[ CPUFloatType{2,3} ]
}
Output:

func (*Tensor) AddOut

func (ts *Tensor) AddOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Add_

func (ts *Tensor) Add_(other *Tensor) (err error)

func (*Tensor) Addbmm

func (ts *Tensor) Addbmm(batch1 *Tensor, batch2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) AddbmmOut

func (ts *Tensor) AddbmmOut(out *Tensor, batch1 *Tensor, batch2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Addbmm_

func (ts *Tensor) Addbmm_(batch1 *Tensor, batch2 *Tensor) (err error)

func (*Tensor) Addcdiv

func (ts *Tensor) Addcdiv(tensor1 *Tensor, tensor2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) AddcdivOut

func (ts *Tensor) AddcdivOut(out *Tensor, tensor1 *Tensor, tensor2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Addcdiv_

func (ts *Tensor) Addcdiv_(tensor1 *Tensor, tensor2 *Tensor) (err error)

func (*Tensor) Addcmul

func (ts *Tensor) Addcmul(tensor1 *Tensor, tensor2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) AddcmulOut

func (ts *Tensor) AddcmulOut(out *Tensor, tensor1 *Tensor, tensor2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Addcmul_

func (ts *Tensor) Addcmul_(tensor1 *Tensor, tensor2 *Tensor) (err error)

func (*Tensor) Addmm

func (ts *Tensor) Addmm(mat1 *Tensor, mat2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) AddmmOut

func (ts *Tensor) AddmmOut(out *Tensor, mat1 *Tensor, mat2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Addmm_

func (ts *Tensor) Addmm_(mat1 *Tensor, mat2 *Tensor) (err error)

func (*Tensor) Addmv

func (ts *Tensor) Addmv(mat *Tensor, vec *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) AddmvOut

func (ts *Tensor) AddmvOut(out *Tensor, mat *Tensor, vec *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Addmv_

func (ts *Tensor) Addmv_(mat *Tensor, vec *Tensor) (err error)

func (*Tensor) Addr

func (ts *Tensor) Addr(vec1 *Tensor, vec2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) AddrOut

func (ts *Tensor) AddrOut(out *Tensor, vec1 *Tensor, vec2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Addr_

func (ts *Tensor) Addr_(vec1 *Tensor, vec2 *Tensor) (err error)

func (*Tensor) Alias

func (ts *Tensor) Alias(del bool) (retVal *Tensor, err error)

func (*Tensor) AlignAs

func (ts *Tensor) AlignAs(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) All

func (ts *Tensor) All(del bool) (retVal *Tensor, err error)

func (*Tensor) All1

func (ts *Tensor) All1(dim int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) AllOut

func (ts *Tensor) AllOut(out *Tensor, dim int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) AlphaDropout_

func (ts *Tensor) AlphaDropout_(p float64, train bool) (err error)

func (*Tensor) Amax added in v0.3.0

func (ts *Tensor) Amax(dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) AmaxOut added in v0.3.0

func (ts *Tensor) AmaxOut(out *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Amin added in v0.3.0

func (ts *Tensor) Amin(dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) AminOut added in v0.3.0

func (ts *Tensor) AminOut(out *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Angle

func (ts *Tensor) Angle(del bool) (retVal *Tensor, err error)

func (*Tensor) AngleOut

func (ts *Tensor) AngleOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Any

func (ts *Tensor) Any(del bool) (retVal *Tensor, err error)

func (*Tensor) Any1

func (ts *Tensor) Any1(dim int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) AnyOut

func (ts *Tensor) AnyOut(out *Tensor, dim int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Apply

func (ts *Tensor) Apply(m Module) (retVal *Tensor)

Apply forwards tensor itself through a module.

func (*Tensor) ApplyCModule

func (ts *Tensor) ApplyCModule(m *CModule) *Tensor

Apply forwards tensor itself through a module.

func (*Tensor) ApplyOpt

func (ts *Tensor) ApplyOpt(opts ...ModuleOption) (retVal *Tensor)

ApplyOpt forwards a tensor itself through a module if given, shallow-copies the tensor otherwise.

func (*Tensor) ApplyOptT

func (ts *Tensor) ApplyOptT(train bool, opts ...ModuleTOption) (retVal *Tensor)

ApplyOptT forwards a tensor itself through a module T if given, shallow-copies the tensor otherwise.

func (*Tensor) ApplyT

func (ts *Tensor) ApplyT(m ModuleT, train bool) (retVal *Tensor)

Apply forwards tensor itself through a module T.

func (*Tensor) Arccos added in v0.3.0

func (ts *Tensor) Arccos(del bool) (retVal *Tensor, err error)

func (*Tensor) ArccosOut added in v0.3.0

func (ts *Tensor) ArccosOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Arccos_ added in v0.3.0

func (ts *Tensor) Arccos_() (err error)

func (*Tensor) Arccosh added in v0.3.0

func (ts *Tensor) Arccosh(del bool) (retVal *Tensor, err error)

func (*Tensor) ArccoshOut added in v0.3.0

func (ts *Tensor) ArccoshOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Arccosh_ added in v0.3.0

func (ts *Tensor) Arccosh_() (err error)

func (*Tensor) Arcsin added in v0.3.0

func (ts *Tensor) Arcsin(del bool) (retVal *Tensor, err error)

func (*Tensor) ArcsinOut added in v0.3.0

func (ts *Tensor) ArcsinOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Arcsin_ added in v0.3.0

func (ts *Tensor) Arcsin_() (err error)

func (*Tensor) Arcsinh added in v0.3.0

func (ts *Tensor) Arcsinh(del bool) (retVal *Tensor, err error)

func (*Tensor) ArcsinhOut added in v0.3.0

func (ts *Tensor) ArcsinhOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Arcsinh_ added in v0.3.0

func (ts *Tensor) Arcsinh_() (err error)

func (*Tensor) Arctan added in v0.3.0

func (ts *Tensor) Arctan(del bool) (retVal *Tensor, err error)

func (*Tensor) ArctanOut added in v0.3.0

func (ts *Tensor) ArctanOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Arctan_ added in v0.3.0

func (ts *Tensor) Arctan_() (err error)

func (*Tensor) Arctanh added in v0.3.0

func (ts *Tensor) Arctanh(del bool) (retVal *Tensor, err error)

func (*Tensor) ArctanhOut added in v0.3.0

func (ts *Tensor) ArctanhOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Arctanh_ added in v0.3.0

func (ts *Tensor) Arctanh_() (err error)

func (*Tensor) Argmax

func (ts *Tensor) Argmax(dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Argmin

func (ts *Tensor) Argmin(dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Argsort

func (ts *Tensor) Argsort(dim int64, descending bool, del bool) (retVal *Tensor, err error)

func (*Tensor) AsStrided

func (ts *Tensor) AsStrided(size []int64, stride []int64, storageOffset []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AsStrided_

func (ts *Tensor) AsStrided_(size []int64, stride []int64, storageOffset []int64) (err error)

func (*Tensor) Asin

func (ts *Tensor) Asin(del bool) (retVal *Tensor, err error)

func (*Tensor) AsinOut

func (ts *Tensor) AsinOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Asin_

func (ts *Tensor) Asin_() (err error)

func (*Tensor) Asinh added in v0.3.0

func (ts *Tensor) Asinh(del bool) (retVal *Tensor, err error)

func (*Tensor) AsinhOut added in v0.3.0

func (ts *Tensor) AsinhOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Asinh_ added in v0.3.0

func (ts *Tensor) Asinh_() (err error)

func (*Tensor) Atan

func (ts *Tensor) Atan(del bool) (retVal *Tensor, err error)

func (*Tensor) Atan2

func (ts *Tensor) Atan2(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Atan2Out

func (ts *Tensor) Atan2Out(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Atan2_

func (ts *Tensor) Atan2_(other *Tensor) (err error)

func (*Tensor) AtanOut

func (ts *Tensor) AtanOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Atan_

func (ts *Tensor) Atan_() (err error)

func (*Tensor) Atanh added in v0.3.0

func (ts *Tensor) Atanh(del bool) (retVal *Tensor, err error)

func (*Tensor) AtanhOut added in v0.3.0

func (ts *Tensor) AtanhOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Atanh_ added in v0.3.0

func (ts *Tensor) Atanh_() (err error)

func (*Tensor) Atleast1d added in v0.3.0

func (ts *Tensor) Atleast1d(del bool) (retVal *Tensor, err error)

func (*Tensor) Atleast2d added in v0.3.0

func (ts *Tensor) Atleast2d(del bool) (retVal *Tensor, err error)

func (*Tensor) Atleast3d added in v0.3.0

func (ts *Tensor) Atleast3d(del bool) (retVal *Tensor, err error)

func (*Tensor) AvgPool1d

func (ts *Tensor) AvgPool1d(kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, del bool) (retVal *Tensor, err error)

func (*Tensor) AvgPool2DDefault

func (ts *Tensor) AvgPool2DDefault(ksize int64, del bool) *Tensor

func (*Tensor) AvgPool2d

func (ts *Tensor) AvgPool2d(kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AvgPool2dBackward

func (ts *Tensor) AvgPool2dBackward(gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AvgPool2dBackwardOut

func (ts *Tensor) AvgPool2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AvgPool2dOut

func (ts *Tensor) AvgPool2dOut(out *Tensor, kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AvgPool3d

func (ts *Tensor) AvgPool3d(kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AvgPool3dBackward

func (ts *Tensor) AvgPool3dBackward(gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AvgPool3dBackwardOut

func (ts *Tensor) AvgPool3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) AvgPool3dOut

func (ts *Tensor) AvgPool3dOut(out *Tensor, kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Backward

func (ts *Tensor) Backward() error

Backward runs the backward pass, populating the gradient tensors for tensors which gradients are tracked.

Gradients tracking can be turned on via `SetRequiresGrad`.

func (*Tensor) Baddbmm

func (ts *Tensor) Baddbmm(batch1 *Tensor, batch2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) BaddbmmOut

func (ts *Tensor) BaddbmmOut(out *Tensor, batch1 *Tensor, batch2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Baddbmm_

func (ts *Tensor) Baddbmm_(batch1 *Tensor, batch2 *Tensor) (err error)

func (*Tensor) Bernoulli

func (ts *Tensor) Bernoulli(del bool) (retVal *Tensor, err error)

func (*Tensor) Bernoulli1

func (ts *Tensor) Bernoulli1(p float64, del bool) (retVal *Tensor, err error)

func (*Tensor) Bernoulli1_

func (ts *Tensor) Bernoulli1_(p float64) (err error)

func (*Tensor) BernoulliOut

func (ts *Tensor) BernoulliOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Bernoulli_

func (ts *Tensor) Bernoulli_(p *Tensor) (err error)

func (*Tensor) BinaryCrossEntropy

func (ts *Tensor) BinaryCrossEntropy(target *Tensor, weight *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) BinaryCrossEntropyBackward

func (ts *Tensor) BinaryCrossEntropyBackward(gradOutput *Tensor, target *Tensor, weight *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) BinaryCrossEntropyBackwardOut

func (ts *Tensor) BinaryCrossEntropyBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, weight *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) BinaryCrossEntropyOut

func (ts *Tensor) BinaryCrossEntropyOut(out *Tensor, target *Tensor, weight *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) BinaryCrossEntropyWithLogits

func (ts *Tensor) BinaryCrossEntropyWithLogits(target *Tensor, weight *Tensor, posWeight *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) BinaryCrossEntropyWithLogitsBackward

func (ts *Tensor) BinaryCrossEntropyWithLogitsBackward(gradOutput *Tensor, target *Tensor, weight *Tensor, posWeight *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Bincount

func (ts *Tensor) Bincount(weights *Tensor, minlength int64, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseAnd

func (ts *Tensor) BitwiseAnd(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseAnd1

func (ts *Tensor) BitwiseAnd1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseAnd1_

func (ts *Tensor) BitwiseAnd1_(other *Tensor) (err error)

func (*Tensor) BitwiseAndOut

func (ts *Tensor) BitwiseAndOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseAndOut1

func (ts *Tensor) BitwiseAndOut1(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseAnd_

func (ts *Tensor) BitwiseAnd_(other *Scalar) (err error)

func (*Tensor) BitwiseNot

func (ts *Tensor) BitwiseNot(del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseNotOut

func (ts *Tensor) BitwiseNotOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseNot_

func (ts *Tensor) BitwiseNot_() (err error)

func (*Tensor) BitwiseOr

func (ts *Tensor) BitwiseOr(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseOr1

func (ts *Tensor) BitwiseOr1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseOr1_

func (ts *Tensor) BitwiseOr1_(other *Tensor) (err error)

func (*Tensor) BitwiseOrOut

func (ts *Tensor) BitwiseOrOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseOrOut1

func (ts *Tensor) BitwiseOrOut1(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseOr_

func (ts *Tensor) BitwiseOr_(other *Scalar) (err error)

func (*Tensor) BitwiseXor

func (ts *Tensor) BitwiseXor(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseXor1

func (ts *Tensor) BitwiseXor1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseXor1_

func (ts *Tensor) BitwiseXor1_(other *Tensor) (err error)

func (*Tensor) BitwiseXorOut

func (ts *Tensor) BitwiseXorOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseXorOut1

func (ts *Tensor) BitwiseXorOut1(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) BitwiseXor_

func (ts *Tensor) BitwiseXor_(other *Scalar) (err error)

func (*Tensor) Bmm

func (ts *Tensor) Bmm(mat2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) BmmOut

func (ts *Tensor) BmmOut(out *Tensor, mat2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Bucketize added in v0.3.0

func (ts *Tensor) Bucketize(boundaries *Tensor, outInt32 bool, right bool, del bool) (retVal *Tensor, err error)

func (*Tensor) BucketizeOut added in v0.3.0

func (ts *Tensor) BucketizeOut(out *Tensor, boundaries *Tensor, outInt32 bool, right bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Cauchy_

func (ts *Tensor) Cauchy_(median float64, sigma float64) (err error)

func (*Tensor) Ceil

func (ts *Tensor) Ceil(del bool) (retVal *Tensor, err error)

func (*Tensor) CeilOut

func (ts *Tensor) CeilOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Ceil_

func (ts *Tensor) Ceil_() (err error)

func (*Tensor) Celu

func (ts *Tensor) Celu(del bool) (retVal *Tensor, err error)

func (*Tensor) Celu_

func (ts *Tensor) Celu_() (err error)

func (*Tensor) ChannelShuffle added in v0.3.0

func (ts *Tensor) ChannelShuffle(groups int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Cholesky

func (ts *Tensor) Cholesky(upper bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CholeskyInverse

func (ts *Tensor) CholeskyInverse(upper bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CholeskyInverseOut

func (ts *Tensor) CholeskyInverseOut(out *Tensor, upper bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CholeskyOut

func (ts *Tensor) CholeskyOut(out *Tensor, upper bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CholeskySolve

func (ts *Tensor) CholeskySolve(input2 *Tensor, upper bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CholeskySolveOut

func (ts *Tensor) CholeskySolveOut(out *Tensor, input2 *Tensor, upper bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Chunk

func (ts *Tensor) Chunk(chunks int64, dim int64) (retVal []Tensor, err error)

tensor *atg_chunk(tensor self, int64_t chunks, int64_t dim);

func (*Tensor) Clamp

func (ts *Tensor) Clamp(min *Scalar, max *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) ClampMax

func (ts *Tensor) ClampMax(max *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) ClampMaxOut

func (ts *Tensor) ClampMaxOut(out *Tensor, max *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) ClampMax_

func (ts *Tensor) ClampMax_(max *Scalar) (err error)

func (*Tensor) ClampMin

func (ts *Tensor) ClampMin(min *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) ClampMinOut

func (ts *Tensor) ClampMinOut(out *Tensor, min *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) ClampMin_

func (ts *Tensor) ClampMin_(min *Scalar) (err error)

func (*Tensor) ClampOut

func (ts *Tensor) ClampOut(out *Tensor, min *Scalar, max *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Clamp_

func (ts *Tensor) Clamp_(min *Scalar, max *Scalar) (err error)

func (*Tensor) Clip added in v0.3.0

func (ts *Tensor) Clip(min *Scalar, max *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) ClipOut added in v0.3.0

func (ts *Tensor) ClipOut(out *Tensor, min *Scalar, max *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Clip_ added in v0.3.0

func (ts *Tensor) Clip_(min *Scalar, max *Scalar) (err error)

func (*Tensor) Coalesce

func (ts *Tensor) Coalesce(del bool) (retVal *Tensor, err error)

func (*Tensor) Col2im

func (ts *Tensor) Col2im(outputSize []int64, kernelSize []int64, dilation []int64, padding []int64, stride []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Col2imOut

func (ts *Tensor) Col2imOut(out *Tensor, outputSize []int64, kernelSize []int64, dilation []int64, padding []int64, stride []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Combinations

func (ts *Tensor) Combinations(r int64, withReplacement bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Conj

func (ts *Tensor) Conj(del bool) (retVal *Tensor, err error)

func (*Tensor) ConjOut

func (ts *Tensor) ConjOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) ConstantPadNd

func (ts *Tensor) ConstantPadNd(pad []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Contiguous

func (ts *Tensor) Contiguous(del bool) (retVal *Tensor, err error)

func (*Tensor) ConvTbc

func (ts *Tensor) ConvTbc(weight *Tensor, bias *Tensor, pad int64, del bool) (retVal *Tensor, err error)

func (*Tensor) CopyData

func (ts *Tensor) CopyData(dst interface{}, numel uint) error

CopyData copies `numel` elements from `self` to `dst`. `dst` should be a slice of Go type equivalent to tensor type.

NOTE: `dst` located in Go memory. Should it be? We will render Go pointer of first element of `dst` slice and number of elements to C land. This may break in the future if Go policy changes.

func (*Tensor) CopyDataUint8

func (ts *Tensor) CopyDataUint8(dst []uint8, numel uint) error

CopyDataUint8 copies `numel` elements from `self` to `dst`.

NOTE: `dst` located in Go memory. Should it be?

func (*Tensor) CopySparseToSparse_

func (ts *Tensor) CopySparseToSparse_(src *Tensor, nonBlocking bool) (err error)

func (*Tensor) Copy_

func (ts *Tensor) Copy_(src *Tensor)

Copy_ copies in-place values from the argument tensor to existing tensor

func (*Tensor) Cos

func (ts *Tensor) Cos(del bool) (retVal *Tensor, err error)

func (*Tensor) CosOut

func (ts *Tensor) CosOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Cos_

func (ts *Tensor) Cos_() (err error)

func (*Tensor) Cosh

func (ts *Tensor) Cosh(del bool) (retVal *Tensor, err error)

func (*Tensor) CoshOut

func (ts *Tensor) CoshOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Cosh_

func (ts *Tensor) Cosh_() (err error)

func (*Tensor) CountNonzero added in v0.3.0

func (ts *Tensor) CountNonzero(dim []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) CountNonzero1 added in v0.3.0

func (ts *Tensor) CountNonzero1(dim []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Cross

func (ts *Tensor) Cross(other *Tensor, dim []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) CrossEntropyForLogits

func (ts *Tensor) CrossEntropyForLogits(targets *Tensor) (retVal *Tensor)

CrossEntropyForLogits computes the cross-entropy loss based on some logits and targets.

func (*Tensor) CrossOut

func (ts *Tensor) CrossOut(out *Tensor, other *Tensor, dim []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) CudnnConvolution

func (ts *Tensor) CudnnConvolution(weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CudnnConvolution1

func (ts *Tensor) CudnnConvolution1(weight *Tensor, bias *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CudnnConvolution2 added in v0.3.0

func (ts *Tensor) CudnnConvolution2(weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, allowTf32 bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CudnnConvolutionBackwardWeight

func (ts *Tensor) CudnnConvolutionBackwardWeight(weightSize []int64, gradOutput *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, allowTf32 bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CudnnConvolutionTranspose

func (ts *Tensor) CudnnConvolutionTranspose(weight *Tensor, padding []int64, outputPadding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CudnnConvolutionTranspose1

func (ts *Tensor) CudnnConvolutionTranspose1(weight *Tensor, bias *Tensor, padding []int64, outputPadding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CudnnConvolutionTranspose2 added in v0.3.0

func (ts *Tensor) CudnnConvolutionTranspose2(weight *Tensor, padding []int64, outputPadding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, allowTf32 bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CudnnConvolutionTransposeBackwardWeight

func (ts *Tensor) CudnnConvolutionTransposeBackwardWeight(weightSize []int64, gradOutput *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, allowTf32 bool, del bool) (retVal *Tensor, err error)

func (*Tensor) CudnnGridSampler

func (ts *Tensor) CudnnGridSampler(grid *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Cumprod

func (ts *Tensor) Cumprod(dim int64, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) CumprodOut

func (ts *Tensor) CumprodOut(out *Tensor, dim int64, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Cumsum

func (ts *Tensor) Cumsum(dim int64, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) CumsumOut

func (ts *Tensor) CumsumOut(out *Tensor, dim int64, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) DType

func (ts *Tensor) DType() gotch.DType

func (*Tensor) Data

func (ts *Tensor) Data(del bool) (retVal *Tensor, err error)

func (*Tensor) DataPtr

func (ts *Tensor) DataPtr() (unsafe.Pointer, error)

DataPtr returns the address of the first element of this tensor.

func (*Tensor) Defined

func (ts *Tensor) Defined() (bool, error)

Defined returns true is the tensor is defined.

func (*Tensor) Deg2rad added in v0.3.0

func (ts *Tensor) Deg2rad(del bool) (retVal *Tensor, err error)

func (*Tensor) Deg2radOut added in v0.3.0

func (ts *Tensor) Deg2radOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Deg2rad_ added in v0.3.0

func (ts *Tensor) Deg2rad_() (err error)

func (*Tensor) Dequantize

func (ts *Tensor) Dequantize(del bool) (retVal *Tensor, err error)

func (*Tensor) Det

func (ts *Tensor) Det(del bool) (retVal *Tensor, err error)

func (*Tensor) Detach

func (ts *Tensor) Detach(del bool) (retVal *Tensor, err error)

func (*Tensor) Detach_

func (ts *Tensor) Detach_() (err error)

func (*Tensor) Device

func (ts *Tensor) Device() (gotch.Device, error)

func (*Tensor) Diag

func (ts *Tensor) Diag(diagonal int64, del bool) (retVal *Tensor, err error)

func (*Tensor) DiagEmbed

func (ts *Tensor) DiagEmbed(offset int64, dim1 int64, dim2 int64, del bool) (retVal *Tensor, err error)

func (*Tensor) DiagOut

func (ts *Tensor) DiagOut(out *Tensor, diagonal int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Diagflat

func (ts *Tensor) Diagflat(offset int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Diagonal

func (ts *Tensor) Diagonal(offset int64, dim1 int64, dim2 int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Digamma

func (ts *Tensor) Digamma(del bool) (retVal *Tensor, err error)

func (*Tensor) DigammaOut

func (ts *Tensor) DigammaOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Digamma_

func (ts *Tensor) Digamma_() (err error)

func (*Tensor) Dim

func (ts *Tensor) Dim() uint64

func (*Tensor) Dist

func (ts *Tensor) Dist(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Div

func (ts *Tensor) Div(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Div1

func (ts *Tensor) Div1(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Div1_

func (ts *Tensor) Div1_(other *Scalar) (err error)

func (*Tensor) DivOut

func (ts *Tensor) DivOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Div_

func (ts *Tensor) Div_(other *Tensor) (err error)

func (*Tensor) Divide added in v0.3.0

func (ts *Tensor) Divide(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Divide1 added in v0.3.0

func (ts *Tensor) Divide1(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Divide1_ added in v0.3.0

func (ts *Tensor) Divide1_(other *Scalar) (err error)

func (*Tensor) DivideOut added in v0.3.0

func (ts *Tensor) DivideOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Divide_ added in v0.3.0

func (ts *Tensor) Divide_(other *Tensor) (err error)

func (*Tensor) Dot

func (ts *Tensor) Dot(tensor *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) DotOut

func (ts *Tensor) DotOut(out *Tensor, tensor *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Drop

func (ts *Tensor) Drop() error

Drop drops (frees) the tensor

func (*Tensor) Dropout_

func (ts *Tensor) Dropout_(p float64, train bool) (err error)

func (*Tensor) Elu

func (ts *Tensor) Elu(del bool) (retVal *Tensor, err error)

func (*Tensor) EluOut

func (ts *Tensor) EluOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Elu_

func (ts *Tensor) Elu_() (err error)

func (*Tensor) EmbeddingRenorm_

func (ts *Tensor) EmbeddingRenorm_(indices *Tensor, maxNorm float64, normType float64) (err error)

func (*Tensor) EmptyLike

func (ts *Tensor) EmptyLike(del bool) (retVal *Tensor, err error)

func (*Tensor) Eq

func (ts *Tensor) Eq(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Eq1

func (ts *Tensor) Eq1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Eq1_

func (ts *Tensor) Eq1_(other *Tensor) (err error)

func (*Tensor) EqOut

func (ts *Tensor) EqOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) EqOut1

func (ts *Tensor) EqOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Eq_

func (ts *Tensor) Eq_(other *Scalar) (err error)

func (*Tensor) Erf

func (ts *Tensor) Erf(del bool) (retVal *Tensor, err error)

func (*Tensor) ErfOut

func (ts *Tensor) ErfOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Erf_

func (ts *Tensor) Erf_() (err error)

func (*Tensor) Erfc

func (ts *Tensor) Erfc(del bool) (retVal *Tensor, err error)

func (*Tensor) ErfcOut

func (ts *Tensor) ErfcOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Erfc_

func (ts *Tensor) Erfc_() (err error)

func (*Tensor) Erfinv

func (ts *Tensor) Erfinv(del bool) (retVal *Tensor, err error)

func (*Tensor) ErfinvOut

func (ts *Tensor) ErfinvOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Erfinv_

func (ts *Tensor) Erfinv_() (err error)

func (*Tensor) Exp

func (ts *Tensor) Exp(del bool) (retVal *Tensor, err error)

func (*Tensor) Exp2 added in v0.3.0

func (ts *Tensor) Exp2(del bool) (retVal *Tensor, err error)

func (*Tensor) Exp2Out added in v0.3.0

func (ts *Tensor) Exp2Out(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Exp2_ added in v0.3.0

func (ts *Tensor) Exp2_() (err error)

func (*Tensor) ExpOut

func (ts *Tensor) ExpOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Exp_

func (ts *Tensor) Exp_() (err error)

func (*Tensor) Expand

func (ts *Tensor) Expand(size []int64, implicit bool, del bool) (retVal *Tensor, err error)

func (*Tensor) ExpandAs

func (ts *Tensor) ExpandAs(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Expm1

func (ts *Tensor) Expm1(del bool) (retVal *Tensor, err error)

func (*Tensor) Expm1Out

func (ts *Tensor) Expm1Out(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Expm1_

func (ts *Tensor) Expm1_() (err error)

func (*Tensor) Exponential_

func (ts *Tensor) Exponential_(lambd float64) (err error)

func (*Tensor) FakeQuantizePerChannelAffine

func (ts *Tensor) FakeQuantizePerChannelAffine(scale *Tensor, zeroPoint *Tensor, axis int64, quantMin int64, quantMax int64, del bool) (retVal *Tensor, err error)

func (*Tensor) FakeQuantizePerChannelAffineBackward

func (ts *Tensor) FakeQuantizePerChannelAffineBackward(grad *Tensor, scale *Tensor, zeroPoint *Tensor, axis int64, quantMin int64, quantMax int64, del bool) (retVal *Tensor, err error)

func (*Tensor) FakeQuantizePerTensorAffine

func (ts *Tensor) FakeQuantizePerTensorAffine(scale float64, zeroPoint int64, quantMin int64, quantMax int64, del bool) (retVal *Tensor, err error)

func (*Tensor) FakeQuantizePerTensorAffineBackward

func (ts *Tensor) FakeQuantizePerTensorAffineBackward(grad *Tensor, scale float64, zeroPoint int64, quantMin int64, quantMax int64, del bool) (retVal *Tensor, err error)

func (*Tensor) FeatureAlphaDropout_

func (ts *Tensor) FeatureAlphaDropout_(p float64, train bool) (err error)

func (*Tensor) FeatureDropout_

func (ts *Tensor) FeatureDropout_(p float64, train bool) (err error)

func (*Tensor) Fft

func (ts *Tensor) Fft(signalNdim int64, normalized bool, del bool) (retVal *Tensor, err error)

func (*Tensor) FftFft added in v0.3.0

func (ts *Tensor) FftFft(n []int64, dim int64, norm string, del bool) (retVal *Tensor, err error)

func (*Tensor) FftFftn added in v0.3.0

func (ts *Tensor) FftFftn(s []int64, dim []int64, norm string, del bool) (retVal *Tensor, err error)

func (*Tensor) FftHfft added in v0.3.0

func (ts *Tensor) FftHfft(n []int64, dim int64, norm string, del bool) (retVal *Tensor, err error)

func (*Tensor) FftIfft added in v0.3.0

func (ts *Tensor) FftIfft(n []int64, dim int64, norm string, del bool) (retVal *Tensor, err error)

func (*Tensor) FftIfftn added in v0.3.0

func (ts *Tensor) FftIfftn(s []int64, dim []int64, norm string, del bool) (retVal *Tensor, err error)

func (*Tensor) FftIhfft added in v0.3.0

func (ts *Tensor) FftIhfft(n []int64, dim int64, norm string, del bool) (retVal *Tensor, err error)

func (*Tensor) FftIrfft added in v0.3.0

func (ts *Tensor) FftIrfft(n []int64, dim int64, norm string, del bool) (retVal *Tensor, err error)

func (*Tensor) FftIrfftn added in v0.3.0

func (ts *Tensor) FftIrfftn(s []int64, dim []int64, norm string, del bool) (retVal *Tensor, err error)

func (*Tensor) FftRfft added in v0.3.0

func (ts *Tensor) FftRfft(n []int64, dim int64, norm string, del bool) (retVal *Tensor, err error)

func (*Tensor) FftRfftn added in v0.3.0

func (ts *Tensor) FftRfftn(s []int64, dim []int64, norm string, del bool) (retVal *Tensor, err error)

func (*Tensor) Fill1_

func (ts *Tensor) Fill1_(value *Tensor) (err error)

func (*Tensor) FillDiagonal_

func (ts *Tensor) FillDiagonal_(fillValue *Scalar, wrap bool) (err error)

func (*Tensor) Fill_

func (ts *Tensor) Fill_(value *Scalar) (err error)

func (*Tensor) Fix added in v0.3.0

func (ts *Tensor) Fix(del bool) (retVal *Tensor, err error)

func (*Tensor) FixOut added in v0.3.0

func (ts *Tensor) FixOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Fix_ added in v0.3.0

func (ts *Tensor) Fix_() (err error)

func (*Tensor) FlatView

func (ts *Tensor) FlatView() *Tensor

FlatView flattens a tensor.

This returns a flattened version of the given tensor. The first dimension is preserved as it is assumed to be the mini-batch dimension.

func (*Tensor) Flatten

func (ts *Tensor) Flatten(startDim int64, endDim int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Flip

func (ts *Tensor) Flip(dims []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Fliplr added in v0.3.0

func (ts *Tensor) Fliplr(del bool) (retVal *Tensor, err error)

func (*Tensor) Flipud added in v0.3.0

func (ts *Tensor) Flipud(del bool) (retVal *Tensor, err error)

func (*Tensor) Float64Value

func (ts *Tensor) Float64Value(idx []int64) (float64, error)
  • func (ts Tensor) Eq1(other Tensor, del bool) (retVal Tensor, err error) { *
  • // Get a C null pointer
  • // https://stackoverflow.com/a/2022369
  • ptr := (*lib.Ctensor)(unsafe.Pointer(C.malloc(0)))
  • if del {
  • defer ts.MustDrop()
  • } *
  • lib.AtgEq1(ptr, ts.ctensor, other.ctensor)
  • if err = TorchErr(); err != nil {
  • return retVal, err
  • } *
  • return Tensor{ctensor: *ptr}, nil *
  • } *
  • func (ts Tensor) MustEq1(other Tensor, del bool) (retVal Tensor) {
  • retVal, err := ts.Eq1(other, del)
  • if err != nil {
  • log.Fatal(err)
  • } *
  • return retVal
  • } *

Float64Value returns a float value on tensors holding a single element. An error is returned otherwise. double at_double_value_at_indexes(tensor, int64_t *indexes, int indexes_len);

func (*Tensor) Float64Values

func (ts *Tensor) Float64Values() []float64

Float64Values returns values of tensor in a slice of float64.

func (*Tensor) Floor

func (ts *Tensor) Floor(del bool) (retVal *Tensor, err error)

func (*Tensor) FloorDivide

func (ts *Tensor) FloorDivide(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) FloorDivide1

func (ts *Tensor) FloorDivide1(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) FloorDivide1_

func (ts *Tensor) FloorDivide1_(other *Scalar) (err error)

func (*Tensor) FloorDivideOut

func (ts *Tensor) FloorDivideOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) FloorDivide_

func (ts *Tensor) FloorDivide_(other *Tensor) (err error)

func (*Tensor) FloorOut

func (ts *Tensor) FloorOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Floor_

func (ts *Tensor) Floor_() (err error)

func (*Tensor) Fmod

func (ts *Tensor) Fmod(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Fmod1

func (ts *Tensor) Fmod1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Fmod1_

func (ts *Tensor) Fmod1_(other *Tensor) (err error)

func (*Tensor) FmodOut

func (ts *Tensor) FmodOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) FmodOut1

func (ts *Tensor) FmodOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Fmod_

func (ts *Tensor) Fmod_(other *Scalar) (err error)

func (*Tensor) Format added in v0.3.2

func (ts *Tensor) Format(s fmt.State, c rune)

Format implements fmt.Formatter interface so that we can use fmt.Print... and verbs to print out Tensor value in different formats.

func (*Tensor) Frac

func (ts *Tensor) Frac(del bool) (retVal *Tensor, err error)

func (*Tensor) FracOut

func (ts *Tensor) FracOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Frac_

func (ts *Tensor) Frac_() (err error)

func (*Tensor) FractionalMaxPool2dBackward

func (ts *Tensor) FractionalMaxPool2dBackward(gradOutput *Tensor, kernelSize []int64, outputSize []int64, indices *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) FractionalMaxPool2dBackwardOut

func (ts *Tensor) FractionalMaxPool2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, outputSize []int64, indices *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) FractionalMaxPool3dBackward

func (ts *Tensor) FractionalMaxPool3dBackward(gradOutput *Tensor, kernelSize []int64, outputSize []int64, indices *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) FractionalMaxPool3dBackwardOut

func (ts *Tensor) FractionalMaxPool3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, outputSize []int64, indices *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) FrobeniusNorm

func (ts *Tensor) FrobeniusNorm(del bool) (retVal *Tensor, err error)

func (*Tensor) FrobeniusNorm1

func (ts *Tensor) FrobeniusNorm1(dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) FrobeniusNormOut

func (ts *Tensor) FrobeniusNormOut(out *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) FullLike

func (ts *Tensor) FullLike(fillValue *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Gather

func (ts *Tensor) Gather(dim int64, index *Tensor, sparseGrad bool, del bool) (retVal *Tensor, err error)

func (*Tensor) GatherBackward added in v0.3.0

func (ts *Tensor) GatherBackward(grad *Tensor, dim int64, index *Tensor, sparseGrad bool, del bool) (retVal *Tensor, err error)

func (*Tensor) GatherOut

func (ts *Tensor) GatherOut(out *Tensor, dim int64, index *Tensor, sparseGrad bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Gcd added in v0.3.0

func (ts *Tensor) Gcd(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) GcdOut added in v0.3.0

func (ts *Tensor) GcdOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Gcd_ added in v0.3.0

func (ts *Tensor) Gcd_(other *Tensor) (err error)

func (*Tensor) Ge

func (ts *Tensor) Ge(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Ge1

func (ts *Tensor) Ge1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Ge1_

func (ts *Tensor) Ge1_(other *Tensor) (err error)

func (*Tensor) GeOut

func (ts *Tensor) GeOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) GeOut1

func (ts *Tensor) GeOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Ge_

func (ts *Tensor) Ge_(other *Scalar) (err error)

func (*Tensor) Gelu

func (ts *Tensor) Gelu(del bool) (retVal *Tensor, err error)

func (*Tensor) GeluBackward

func (ts *Tensor) GeluBackward(grad *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Geometric_

func (ts *Tensor) Geometric_(p float64) (err error)

func (*Tensor) Ger

func (ts *Tensor) Ger(vec2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) GerOut

func (ts *Tensor) GerOut(out *Tensor, vec2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Get

func (ts *Tensor) Get(index int) (*Tensor, error)

Get gets the sub-tensor at the given index.

func (*Tensor) Glu

func (ts *Tensor) Glu(dim int64, del bool) (retVal *Tensor, err error)

func (*Tensor) GluBackward

func (ts *Tensor) GluBackward(gradOutput *Tensor, dim int64, del bool) (retVal *Tensor, err error)

func (*Tensor) GluBackwardOut

func (ts *Tensor) GluBackwardOut(gradInput *Tensor, gradOutput *Tensor, dim int64, del bool) (retVal *Tensor, err error)

func (*Tensor) GluOut

func (ts *Tensor) GluOut(out *Tensor, dim int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Grad

func (ts *Tensor) Grad(del bool) (retVal *Tensor, err error)

func (*Tensor) Greater added in v0.3.0

func (ts *Tensor) Greater(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Greater1 added in v0.3.0

func (ts *Tensor) Greater1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Greater1_ added in v0.3.0

func (ts *Tensor) Greater1_(other *Tensor) (err error)

func (*Tensor) GreaterEqual added in v0.3.0

func (ts *Tensor) GreaterEqual(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) GreaterEqual1 added in v0.3.0

func (ts *Tensor) GreaterEqual1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) GreaterEqual1_ added in v0.3.0

func (ts *Tensor) GreaterEqual1_(other *Tensor) (err error)

func (*Tensor) GreaterEqualOut added in v0.3.0

func (ts *Tensor) GreaterEqualOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) GreaterEqualOut1 added in v0.3.0

func (ts *Tensor) GreaterEqualOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) GreaterEqual_ added in v0.3.0

func (ts *Tensor) GreaterEqual_(other *Scalar) (err error)

func (*Tensor) GreaterOut added in v0.3.0

func (ts *Tensor) GreaterOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) GreaterOut1 added in v0.3.0

func (ts *Tensor) GreaterOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Greater_ added in v0.3.0

func (ts *Tensor) Greater_(other *Scalar) (err error)

func (*Tensor) Gru

func (ts *Tensor) Gru(hx *Tensor, paramsData []Tensor, hasBiases bool, numLayers int64, dropout float64, train bool, bidirectional bool, batchFirst bool) (output, h *Tensor, err error)

func (*Tensor) Gt

func (ts *Tensor) Gt(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Gt1

func (ts *Tensor) Gt1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Gt1_

func (ts *Tensor) Gt1_(other *Tensor) (err error)

func (*Tensor) GtOut

func (ts *Tensor) GtOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) GtOut1

func (ts *Tensor) GtOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Gt_

func (ts *Tensor) Gt_(other *Scalar) (err error)

func (*Tensor) Hardshrink

func (ts *Tensor) Hardshrink(del bool) (retVal *Tensor, err error)

func (*Tensor) HardshrinkBackward

func (ts *Tensor) HardshrinkBackward(gradOut *Tensor, lambd *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Hardsigmoid

func (ts *Tensor) Hardsigmoid(del bool) (retVal *Tensor, err error)

func (*Tensor) HardsigmoidBackward

func (ts *Tensor) HardsigmoidBackward(gradOutput *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) HardsigmoidOut

func (ts *Tensor) HardsigmoidOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Hardsigmoid_

func (ts *Tensor) Hardsigmoid_() (err error)

func (*Tensor) Hardswish added in v0.3.0

func (ts *Tensor) Hardswish(del bool) (retVal *Tensor, err error)

func (*Tensor) HardswishBackward added in v0.3.0

func (ts *Tensor) HardswishBackward(gradOutput *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) HardswishOut added in v0.3.0

func (ts *Tensor) HardswishOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Hardswish_ added in v0.3.0

func (ts *Tensor) Hardswish_() (err error)

func (*Tensor) Hardtanh

func (ts *Tensor) Hardtanh(del bool) (retVal *Tensor, err error)

func (*Tensor) HardtanhBackward

func (ts *Tensor) HardtanhBackward(gradOutput *Tensor, minVal *Scalar, maxVal *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) HardtanhBackwardOut

func (ts *Tensor) HardtanhBackwardOut(gradInput *Tensor, gradOutput *Tensor, minVal *Scalar, maxVal *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) HardtanhOut

func (ts *Tensor) HardtanhOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Hardtanh_

func (ts *Tensor) Hardtanh_() (err error)

func (*Tensor) Heaviside added in v0.3.0

func (ts *Tensor) Heaviside(values *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) HeavisideOut added in v0.3.0

func (ts *Tensor) HeavisideOut(out *Tensor, values *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Heaviside_ added in v0.3.0

func (ts *Tensor) Heaviside_(values *Tensor) (err error)

func (*Tensor) HingeEmbeddingLoss

func (ts *Tensor) HingeEmbeddingLoss(target *Tensor, margin float64, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Histc

func (ts *Tensor) Histc(bins int64, del bool) (retVal *Tensor, err error)

func (*Tensor) HistcOut

func (ts *Tensor) HistcOut(out *Tensor, bins int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Hypot added in v0.3.0

func (ts *Tensor) Hypot(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) HypotOut added in v0.3.0

func (ts *Tensor) HypotOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Hypot_ added in v0.3.0

func (ts *Tensor) Hypot_(other *Tensor) (err error)

func (*Tensor) I0 added in v0.3.0

func (ts *Tensor) I0(del bool) (retVal *Tensor, err error)

func (*Tensor) I0Out added in v0.3.0

func (ts *Tensor) I0Out(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) I0_ added in v0.3.0

func (ts *Tensor) I0_() (err error)

func (*Tensor) Idx

func (ts *Tensor) Idx(index interface{}) (retVal *Tensor)

Idx implements `IndexOp` interface for Tensor

NOTE: - `index`: expects type `TensorIndexer` or `[]TensorIndexer`

func (*Tensor) Ifft

func (ts *Tensor) Ifft(signalNdim int64, normalized bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Im2col

func (ts *Tensor) Im2col(kernelSize []int64, dilation []int64, padding []int64, stride []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Im2colOut

func (ts *Tensor) Im2colOut(out *Tensor, kernelSize []int64, dilation []int64, padding []int64, stride []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Imag

func (ts *Tensor) Imag(del bool) (retVal *Tensor, err error)

func (*Tensor) Index

func (ts *Tensor) Index(indices []Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) IndexAdd

func (ts *Tensor) IndexAdd(dim int64, index *Tensor, source *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) IndexAdd_

func (ts *Tensor) IndexAdd_(dim int64, index *Tensor, source *Tensor) (err error)

func (*Tensor) IndexCopy

func (ts *Tensor) IndexCopy(dim int64, index *Tensor, source *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) IndexCopy_

func (ts *Tensor) IndexCopy_(dim int64, index *Tensor, source *Tensor) (err error)

func (*Tensor) IndexFill

func (ts *Tensor) IndexFill(dim int64, index *Tensor, value *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) IndexFill1

func (ts *Tensor) IndexFill1(dim int64, index *Tensor, value *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) IndexFill1_

func (ts *Tensor) IndexFill1_(dim int64, index *Tensor, value *Tensor) (err error)

func (*Tensor) IndexFill_

func (ts *Tensor) IndexFill_(dim int64, index *Tensor, value *Scalar) (err error)

func (*Tensor) IndexPut

func (ts *Tensor) IndexPut(indices []Tensor, values *Tensor, accumulate bool, del bool) (retVal *Tensor, err error)

func (*Tensor) IndexPut_

func (ts *Tensor) IndexPut_(indices []Tensor, values *Tensor, accumulate bool) (err error)

func (*Tensor) IndexSelect

func (ts *Tensor) IndexSelect(dim int64, index *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) IndexSelectOut

func (ts *Tensor) IndexSelectOut(out *Tensor, dim int64, index *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Indices

func (ts *Tensor) Indices(del bool) (retVal *Tensor, err error)

func (*Tensor) InfinitelyDifferentiableGeluBackward added in v0.3.0

func (ts *Tensor) InfinitelyDifferentiableGeluBackward(grad *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Int64Value

func (ts *Tensor) Int64Value(idx []int64) (int64, error)

Int64Value returns an int value on tensors holding a single element. An error is returned otherwise.

func (*Tensor) Int64Values

func (ts *Tensor) Int64Values() []int64

Int64Values returns values of tensor in a slice of int64.

func (*Tensor) IntRepr

func (ts *Tensor) IntRepr(del bool) (retVal *Tensor, err error)

func (*Tensor) Inverse

func (ts *Tensor) Inverse(del bool) (retVal *Tensor, err error)

func (*Tensor) InverseOut

func (ts *Tensor) InverseOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Irfft

func (ts *Tensor) Irfft(signalNdim int64, normalized bool, onesided bool, signalSizes []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) IsSparse

func (ts *Tensor) IsSparse() (bool, error)

IsSparse returns true is the tensor is spare.

func (*Tensor) Isclose

func (ts *Tensor) Isclose(other *Tensor, rtol float64, atol float64, equalNan bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Isfinite

func (ts *Tensor) Isfinite(del bool) (retVal *Tensor, err error)

func (*Tensor) Isinf

func (ts *Tensor) Isinf(del bool) (retVal *Tensor, err error)

func (*Tensor) Isnan

func (ts *Tensor) Isnan(del bool) (retVal *Tensor, err error)

func (*Tensor) Isneginf added in v0.3.0

func (ts *Tensor) Isneginf(del bool) (retVal *Tensor, err error)

func (*Tensor) IsneginfOut added in v0.3.0

func (ts *Tensor) IsneginfOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Isposinf added in v0.3.0

func (ts *Tensor) Isposinf(del bool) (retVal *Tensor, err error)

func (*Tensor) IsposinfOut added in v0.3.0

func (ts *Tensor) IsposinfOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Isreal added in v0.3.0

func (ts *Tensor) Isreal(del bool) (retVal *Tensor, err error)

func (*Tensor) Istft added in v0.3.0

func (ts *Tensor) Istft(nFft int64, hopLength []int64, winLength []int64, window *Tensor, center bool, normalized bool, onesided bool, length []int64, returnComplex bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Iter

func (ts *Tensor) Iter(dtype gotch.DType) (*Iterable, error)

Iter creates an iterable object with specified item type.

func (*Tensor) KlDiv

func (ts *Tensor) KlDiv(target *Tensor, reduction int64, logTarget bool, del bool) (retVal *Tensor, err error)

func (*Tensor) KlDivBackward

func (ts *Tensor) KlDivBackward(gradOutput *Tensor, target *Tensor, reduction int64, logTarget bool, del bool) (retVal *Tensor, err error)

func (*Tensor) L1Loss

func (ts *Tensor) L1Loss(target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) L1LossBackward

func (ts *Tensor) L1LossBackward(gradOutput *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) L1LossBackwardOut

func (ts *Tensor) L1LossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) L1LossOut

func (ts *Tensor) L1LossOut(out *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Lcm added in v0.3.0

func (ts *Tensor) Lcm(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LcmOut added in v0.3.0

func (ts *Tensor) LcmOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Lcm_ added in v0.3.0

func (ts *Tensor) Lcm_(other *Tensor) (err error)

func (*Tensor) Le

func (ts *Tensor) Le(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Le1

func (ts *Tensor) Le1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Le1_

func (ts *Tensor) Le1_(other *Tensor) (err error)

func (*Tensor) LeOut

func (ts *Tensor) LeOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) LeOut1

func (ts *Tensor) LeOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Le_

func (ts *Tensor) Le_(other *Scalar) (err error)

func (*Tensor) LeakyRelu

func (ts *Tensor) LeakyRelu(del bool) (retVal *Tensor, err error)

func (*Tensor) LeakyReluBackward

func (ts *Tensor) LeakyReluBackward(gradOutput *Tensor, negativeSlope *Scalar, selfIsResult bool, del bool) (retVal *Tensor, err error)

func (*Tensor) LeakyReluOut

func (ts *Tensor) LeakyReluOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LeakyRelu_

func (ts *Tensor) LeakyRelu_() (err error)

func (*Tensor) Lerp

func (ts *Tensor) Lerp(end *Tensor, weight *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Lerp1

func (ts *Tensor) Lerp1(end *Tensor, weight *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Lerp1_

func (ts *Tensor) Lerp1_(end *Tensor, weight *Tensor) (err error)

func (*Tensor) LerpOut

func (ts *Tensor) LerpOut(out *Tensor, end *Tensor, weight *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) LerpOut1

func (ts *Tensor) LerpOut1(out *Tensor, end *Tensor, weight *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Lerp_

func (ts *Tensor) Lerp_(end *Tensor, weight *Scalar) (err error)

func (*Tensor) Less added in v0.3.0

func (ts *Tensor) Less(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Less1 added in v0.3.0

func (ts *Tensor) Less1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Less1_ added in v0.3.0

func (ts *Tensor) Less1_(other *Tensor) (err error)

func (*Tensor) LessEqual added in v0.3.0

func (ts *Tensor) LessEqual(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) LessEqual1 added in v0.3.0

func (ts *Tensor) LessEqual1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LessEqual1_ added in v0.3.0

func (ts *Tensor) LessEqual1_(other *Tensor) (err error)

func (*Tensor) LessEqualOut added in v0.3.0

func (ts *Tensor) LessEqualOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) LessEqualOut1 added in v0.3.0

func (ts *Tensor) LessEqualOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LessEqual_ added in v0.3.0

func (ts *Tensor) LessEqual_(other *Scalar) (err error)

func (*Tensor) LessOut added in v0.3.0

func (ts *Tensor) LessOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) LessOut1 added in v0.3.0

func (ts *Tensor) LessOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Less_ added in v0.3.0

func (ts *Tensor) Less_(other *Scalar) (err error)

func (*Tensor) Lgamma

func (ts *Tensor) Lgamma(del bool) (retVal *Tensor, err error)

func (*Tensor) LgammaOut

func (ts *Tensor) LgammaOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Lgamma_

func (ts *Tensor) Lgamma_() (err error)

func (*Tensor) LinalgDet added in v0.3.0

func (ts *Tensor) LinalgDet(del bool) (retVal *Tensor, err error)

func (*Tensor) LinalgNorm added in v0.3.0

func (ts *Tensor) LinalgNorm(ord *Scalar, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) LinalgNorm1 added in v0.3.0

func (ts *Tensor) LinalgNorm1(ord string, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) LinalgNormOut added in v0.3.0

func (ts *Tensor) LinalgNormOut(out *Tensor, ord *Scalar, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) LinalgNormOut1 added in v0.3.0

func (ts *Tensor) LinalgNormOut1(out *Tensor, ord string, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Log

func (ts *Tensor) Log(del bool) (retVal *Tensor, err error)

func (*Tensor) Log10

func (ts *Tensor) Log10(del bool) (retVal *Tensor, err error)

func (*Tensor) Log10Out

func (ts *Tensor) Log10Out(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Log10_

func (ts *Tensor) Log10_() (err error)

func (*Tensor) Log1p

func (ts *Tensor) Log1p(del bool) (retVal *Tensor, err error)

func (*Tensor) Log1pOut

func (ts *Tensor) Log1pOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Log1p_

func (ts *Tensor) Log1p_() (err error)

func (*Tensor) Log2

func (ts *Tensor) Log2(del bool) (retVal *Tensor, err error)

func (*Tensor) Log2Out

func (ts *Tensor) Log2Out(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Log2_

func (ts *Tensor) Log2_() (err error)

func (*Tensor) LogNormal_

func (ts *Tensor) LogNormal_(mean float64, std float64) (err error)

func (*Tensor) LogOut

func (ts *Tensor) LogOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LogSigmoid

func (ts *Tensor) LogSigmoid(del bool) (retVal *Tensor, err error)

func (*Tensor) LogSigmoidBackward

func (ts *Tensor) LogSigmoidBackward(gradOutput *Tensor, buffer *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LogSigmoidBackwardOut

func (ts *Tensor) LogSigmoidBackwardOut(gradInput *Tensor, gradOutput *Tensor, buffer *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LogSigmoidOut

func (ts *Tensor) LogSigmoidOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LogSoftmax

func (ts *Tensor) LogSoftmax(dim int64, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Log_

func (ts *Tensor) Log_() (err error)

func (*Tensor) Logaddexp added in v0.3.0

func (ts *Tensor) Logaddexp(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Logaddexp2 added in v0.3.0

func (ts *Tensor) Logaddexp2(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Logaddexp2Out added in v0.3.0

func (ts *Tensor) Logaddexp2Out(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LogaddexpOut added in v0.3.0

func (ts *Tensor) LogaddexpOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Logcumsumexp added in v0.3.0

func (ts *Tensor) Logcumsumexp(dim int64, del bool) (retVal *Tensor, err error)

func (*Tensor) LogcumsumexpOut added in v0.3.0

func (ts *Tensor) LogcumsumexpOut(out *Tensor, dim int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Logdet

func (ts *Tensor) Logdet(del bool) (retVal *Tensor, err error)

func (*Tensor) LogicalAnd

func (ts *Tensor) LogicalAnd(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LogicalAndOut

func (ts *Tensor) LogicalAndOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LogicalAnd_

func (ts *Tensor) LogicalAnd_(other *Tensor) (err error)

func (*Tensor) LogicalNot

func (ts *Tensor) LogicalNot(del bool) (retVal *Tensor, err error)

func (*Tensor) LogicalNotOut

func (ts *Tensor) LogicalNotOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LogicalNot_

func (ts *Tensor) LogicalNot_() (err error)

func (*Tensor) LogicalOr

func (ts *Tensor) LogicalOr(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LogicalOrOut

func (ts *Tensor) LogicalOrOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LogicalOr_

func (ts *Tensor) LogicalOr_(other *Tensor) (err error)

func (*Tensor) LogicalXor

func (ts *Tensor) LogicalXor(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LogicalXorOut

func (ts *Tensor) LogicalXorOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LogicalXor_

func (ts *Tensor) LogicalXor_(other *Tensor) (err error)

func (*Tensor) Logit added in v0.3.0

func (ts *Tensor) Logit(eps []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) LogitBackward added in v0.3.0

func (ts *Tensor) LogitBackward(gradOutput *Tensor, eps []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) LogitBackwardOut added in v0.3.0

func (ts *Tensor) LogitBackwardOut(gradInput *Tensor, gradOutput *Tensor, eps []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) LogitOut added in v0.3.0

func (ts *Tensor) LogitOut(out *Tensor, eps []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) Logit_ added in v0.3.0

func (ts *Tensor) Logit_(eps []float64) (err error)

func (*Tensor) Logsumexp

func (ts *Tensor) Logsumexp(dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) LogsumexpOut

func (ts *Tensor) LogsumexpOut(out *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Lstm

func (ts *Tensor) Lstm(hxData []Tensor, paramsData []Tensor, hasBiases bool, numLayers int64, dropout float64, train bool, bidirectional bool, batchFirst bool) (output, h, c *Tensor, err error)

func (*Tensor) Lstsq added in v0.3.9

func (ts *Tensor) Lstsq(a *Tensor, del bool) (retVal *Tensor, err error)

void atg_lstsq(tensor *, tensor self, tensor A);

func (*Tensor) Lt

func (ts *Tensor) Lt(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Lt1

func (ts *Tensor) Lt1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Lt1_

func (ts *Tensor) Lt1_(other *Tensor) (err error)

func (*Tensor) LtOut

func (ts *Tensor) LtOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) LtOut1

func (ts *Tensor) LtOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Lt_

func (ts *Tensor) Lt_(other *Scalar) (err error)

func (*Tensor) LuSolve

func (ts *Tensor) LuSolve(lUData *Tensor, lUPivots *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) LuSolveOut

func (ts *Tensor) LuSolveOut(out *Tensor, lUData *Tensor, lUPivots *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MaskedFill

func (ts *Tensor) MaskedFill(mask *Tensor, value *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) MaskedFill1

func (ts *Tensor) MaskedFill1(mask *Tensor, value *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MaskedFill1_

func (ts *Tensor) MaskedFill1_(mask *Tensor, value *Tensor) (err error)

func (*Tensor) MaskedFill_

func (ts *Tensor) MaskedFill_(mask *Tensor, value *Scalar) (err error)

func (*Tensor) MaskedScatter

func (ts *Tensor) MaskedScatter(mask *Tensor, source *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MaskedScatter_

func (ts *Tensor) MaskedScatter_(mask *Tensor, source *Tensor) (err error)

func (*Tensor) MaskedSelect

func (ts *Tensor) MaskedSelect(mask *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MaskedSelectOut

func (ts *Tensor) MaskedSelectOut(out *Tensor, mask *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Matmul

func (ts *Tensor) Matmul(other *Tensor, del bool) (retVal *Tensor, err error)
Example
package main

import (
	"fmt"

	"github.com/sugarme/gotch"
	ts "github.com/sugarme/gotch/tensor"
)

func main() {
	// Basic tensor operations
	ts1 := ts.MustArange(ts.IntScalar(6), gotch.Int64, gotch.CPU).MustView([]int64{2, 3}, true)
	defer ts1.MustDrop()
	ts2 := ts.MustOnes([]int64{3, 4}, gotch.Int64, gotch.CPU)
	defer ts2.MustDrop()

	mul := ts1.MustMatmul(ts2, false)
	defer mul.MustDrop()
	fmt.Println("ts1: ")
	ts1.Print()
	fmt.Println("ts2: ")
	ts2.Print()
	fmt.Println("mul tensor (ts1 x ts2): ")
	mul.Print()

	//ts1:
	// 0  1  2
	// 3  4  5
	//[ CPULongType{2,3} ]
	//ts2:
	// 1  1  1  1
	// 1  1  1  1
	// 1  1  1  1
	//[ CPULongType{3,4} ]
	//mul tensor (ts1 x ts2):
	//  3   3   3   3
	// 12  12  12  12
	//[ CPULongType{2,4} ]

}
Output:

func (*Tensor) MatmulOut

func (ts *Tensor) MatmulOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MatrixExp added in v0.3.0

func (ts *Tensor) MatrixExp(del bool) (retVal *Tensor, err error)

func (*Tensor) MatrixExpBackward added in v0.3.0

func (ts *Tensor) MatrixExpBackward(grad *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MatrixPower

func (ts *Tensor) MatrixPower(n int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MatrixRank

func (ts *Tensor) MatrixRank(symmetric bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MatrixRank1

func (ts *Tensor) MatrixRank1(tol float64, symmetric bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Max

func (ts *Tensor) Max(del bool) (retVal *Tensor, err error)

func (*Tensor) Max1

func (ts *Tensor) Max1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxOut

func (ts *Tensor) MaxOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxPool1d

func (ts *Tensor) MaxPool1d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxPool2DDefault

func (ts *Tensor) MaxPool2DDefault(ksize int64, del bool) (retVal *Tensor)

func (*Tensor) MaxPool2d

func (ts *Tensor) MaxPool2d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxPool2dWithIndicesBackward

func (ts *Tensor) MaxPool2dWithIndicesBackward(gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, indices *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxPool2dWithIndicesBackwardOut

func (ts *Tensor) MaxPool2dWithIndicesBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, indices *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxPool3d

func (ts *Tensor) MaxPool3d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxPool3dWithIndicesBackward

func (ts *Tensor) MaxPool3dWithIndicesBackward(gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, indices *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxPool3dWithIndicesBackwardOut

func (ts *Tensor) MaxPool3dWithIndicesBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, indices *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxUnpool2d

func (ts *Tensor) MaxUnpool2d(indices *Tensor, outputSize []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxUnpool2dBackward

func (ts *Tensor) MaxUnpool2dBackward(gradOutput *Tensor, indices *Tensor, outputSize []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxUnpool2dBackwardOut

func (ts *Tensor) MaxUnpool2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, indices *Tensor, outputSize []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxUnpool2dOut

func (ts *Tensor) MaxUnpool2dOut(out *Tensor, indices *Tensor, outputSize []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxUnpool3d

func (ts *Tensor) MaxUnpool3d(indices *Tensor, outputSize []int64, stride []int64, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxUnpool3dBackward

func (ts *Tensor) MaxUnpool3dBackward(gradOutput *Tensor, indices *Tensor, outputSize []int64, stride []int64, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxUnpool3dBackwardOut

func (ts *Tensor) MaxUnpool3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, indices *Tensor, outputSize []int64, stride []int64, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MaxUnpool3dOut

func (ts *Tensor) MaxUnpool3dOut(out *Tensor, indices *Tensor, outputSize []int64, stride []int64, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Maximum added in v0.3.0

func (ts *Tensor) Maximum(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MaximumOut added in v0.3.0

func (ts *Tensor) MaximumOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Mean

func (ts *Tensor) Mean(dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Mean1

func (ts *Tensor) Mean1(dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) MeanOut

func (ts *Tensor) MeanOut(out *Tensor, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Median

func (ts *Tensor) Median(del bool) (retVal *Tensor, err error)

func (*Tensor) Meshgrid

func (ts *Tensor) Meshgrid(tensors []Tensor) (retVal []Tensor, err error)

tensor *atg_meshgrid(tensor *tensors_data, int tensors_len);

func (*Tensor) Min

func (ts *Tensor) Min(del bool) (retVal *Tensor, err error)

func (*Tensor) Min1

func (ts *Tensor) Min1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MinOut

func (ts *Tensor) MinOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Minimum added in v0.3.0

func (ts *Tensor) Minimum(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MinimumOut added in v0.3.0

func (ts *Tensor) MinimumOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MiopenConvolution

func (ts *Tensor) MiopenConvolution(weight *Tensor, bias *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MiopenConvolutionBackwardWeight

func (ts *Tensor) MiopenConvolutionBackwardWeight(weightSize []int64, gradOutput *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MiopenConvolutionTranspose

func (ts *Tensor) MiopenConvolutionTranspose(weight *Tensor, bias *Tensor, padding []int64, outputPadding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MiopenConvolutionTransposeBackwardWeight

func (ts *Tensor) MiopenConvolutionTransposeBackwardWeight(weightSize []int64, gradOutput *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MiopenDepthwiseConvolution

func (ts *Tensor) MiopenDepthwiseConvolution(weight *Tensor, bias *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MiopenDepthwiseConvolutionBackwardWeight

func (ts *Tensor) MiopenDepthwiseConvolutionBackwardWeight(weightSize []int64, gradOutput *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MkldnnAdaptiveAvgPool2d

func (ts *Tensor) MkldnnAdaptiveAvgPool2d(outputSize []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MkldnnConvolution

func (ts *Tensor) MkldnnConvolution(weight *Tensor, bias *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MkldnnMaxPool2d

func (ts *Tensor) MkldnnMaxPool2d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MkldnnMaxPool3d added in v0.3.0

func (ts *Tensor) MkldnnMaxPool3d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MkldnnReorderConv2dWeight

func (ts *Tensor) MkldnnReorderConv2dWeight(padding []int64, stride []int64, dilation []int64, groups int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MkldnnReorderConv3dWeight added in v0.3.0

func (ts *Tensor) MkldnnReorderConv3dWeight(padding []int64, stride []int64, dilation []int64, groups int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Mm

func (ts *Tensor) Mm(mat2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MmOut

func (ts *Tensor) MmOut(out *Tensor, mat2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Movedim added in v0.3.0

func (ts *Tensor) Movedim(source []int64, destination []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Movedim1 added in v0.3.0

func (ts *Tensor) Movedim1(source int64, destination int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MseLoss

func (ts *Tensor) MseLoss(target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MseLossBackward

func (ts *Tensor) MseLossBackward(gradOutput *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MseLossBackwardOut

func (ts *Tensor) MseLossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MseLossOut

func (ts *Tensor) MseLossOut(out *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Mul

func (ts *Tensor) Mul(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Mul1

func (ts *Tensor) Mul1(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Mul1_

func (ts *Tensor) Mul1_(other *Scalar) (err error)

func (*Tensor) MulOut

func (ts *Tensor) MulOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Mul_

func (ts *Tensor) Mul_(other *Tensor) (err error)

func (*Tensor) MultiMarginLossBackward

func (ts *Tensor) MultiMarginLossBackward(gradOutput *Tensor, target *Tensor, p *Scalar, margin *Scalar, weight *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MultiMarginLossBackwardOut

func (ts *Tensor) MultiMarginLossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, p *Scalar, margin *Scalar, weight *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MultilabelMarginLoss

func (ts *Tensor) MultilabelMarginLoss(target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) MultilabelMarginLossBackward

func (ts *Tensor) MultilabelMarginLossBackward(gradOutput *Tensor, target *Tensor, reduction int64, isTarget *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MultilabelMarginLossBackwardOut

func (ts *Tensor) MultilabelMarginLossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, reduction int64, isTarget *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MultilabelMarginLossOut

func (ts *Tensor) MultilabelMarginLossOut(out *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Multinomial

func (ts *Tensor) Multinomial(numSamples int64, replacement bool, del bool) (retVal *Tensor, err error)

func (*Tensor) MultinomialOut

func (ts *Tensor) MultinomialOut(out *Tensor, numSamples int64, replacement bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Multiply added in v0.3.0

func (ts *Tensor) Multiply(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Multiply1 added in v0.3.0

func (ts *Tensor) Multiply1(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Multiply1_ added in v0.3.0

func (ts *Tensor) Multiply1_(other *Scalar) (err error)

func (*Tensor) MultiplyOut added in v0.3.0

func (ts *Tensor) MultiplyOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Multiply_ added in v0.3.0

func (ts *Tensor) Multiply_(other *Tensor) (err error)

func (*Tensor) MustAbs

func (ts *Tensor) MustAbs(del bool) (retVal *Tensor)

func (*Tensor) MustAbsOut

func (ts *Tensor) MustAbsOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAbs_

func (ts *Tensor) MustAbs_()

func (*Tensor) MustAbsolute added in v0.3.0

func (ts *Tensor) MustAbsolute(del bool) (retVal *Tensor)

func (*Tensor) MustAbsoluteOut added in v0.3.0

func (ts *Tensor) MustAbsoluteOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAbsolute_ added in v0.3.0

func (ts *Tensor) MustAbsolute_()

func (*Tensor) MustAcos

func (ts *Tensor) MustAcos(del bool) (retVal *Tensor)

func (*Tensor) MustAcosOut

func (ts *Tensor) MustAcosOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAcos_

func (ts *Tensor) MustAcos_()

func (*Tensor) MustAcosh added in v0.3.0

func (ts *Tensor) MustAcosh(del bool) (retVal *Tensor)

func (*Tensor) MustAcoshOut added in v0.3.0

func (ts *Tensor) MustAcoshOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAcosh_ added in v0.3.0

func (ts *Tensor) MustAcosh_()

func (*Tensor) MustAdaptiveAvgPool1d

func (ts *Tensor) MustAdaptiveAvgPool1d(outputSize []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAdaptiveAvgPool2d

func (ts *Tensor) MustAdaptiveAvgPool2d(outputSize []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAdaptiveAvgPool2dOut

func (ts *Tensor) MustAdaptiveAvgPool2dOut(out *Tensor, outputSize []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAdaptiveAvgPool3d

func (ts *Tensor) MustAdaptiveAvgPool3d(outputSize []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAdaptiveAvgPool3dBackward

func (ts *Tensor) MustAdaptiveAvgPool3dBackward(gradOutput *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAdaptiveAvgPool3dBackwardOut

func (ts *Tensor) MustAdaptiveAvgPool3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAdaptiveAvgPool3dOut

func (ts *Tensor) MustAdaptiveAvgPool3dOut(out *Tensor, outputSize []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAdaptiveMaxPool2dBackward

func (ts *Tensor) MustAdaptiveMaxPool2dBackward(gradOutput *Tensor, indices *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAdaptiveMaxPool2dBackwardOut

func (ts *Tensor) MustAdaptiveMaxPool2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, indices *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAdaptiveMaxPool3dBackward

func (ts *Tensor) MustAdaptiveMaxPool3dBackward(gradOutput *Tensor, indices *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAdaptiveMaxPool3dBackwardOut

func (ts *Tensor) MustAdaptiveMaxPool3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, indices *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAdd

func (ts *Tensor) MustAdd(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAdd1

func (ts *Tensor) MustAdd1(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustAdd1_

func (ts *Tensor) MustAdd1_(other *Scalar)

func (*Tensor) MustAddOut

func (ts *Tensor) MustAddOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAdd_

func (ts *Tensor) MustAdd_(other *Tensor)

func (*Tensor) MustAddbmm

func (ts *Tensor) MustAddbmm(batch1 *Tensor, batch2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAddbmmOut

func (ts *Tensor) MustAddbmmOut(out *Tensor, batch1 *Tensor, batch2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAddbmm_

func (ts *Tensor) MustAddbmm_(batch1 *Tensor, batch2 *Tensor)

func (*Tensor) MustAddcdiv

func (ts *Tensor) MustAddcdiv(tensor1 *Tensor, tensor2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAddcdivOut

func (ts *Tensor) MustAddcdivOut(out *Tensor, tensor1 *Tensor, tensor2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAddcdiv_

func (ts *Tensor) MustAddcdiv_(tensor1 *Tensor, tensor2 *Tensor)

func (*Tensor) MustAddcmul

func (ts *Tensor) MustAddcmul(tensor1 *Tensor, tensor2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAddcmulOut

func (ts *Tensor) MustAddcmulOut(out *Tensor, tensor1 *Tensor, tensor2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAddcmul_

func (ts *Tensor) MustAddcmul_(tensor1 *Tensor, tensor2 *Tensor)

func (*Tensor) MustAddmm

func (ts *Tensor) MustAddmm(mat1 *Tensor, mat2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAddmmOut

func (ts *Tensor) MustAddmmOut(out *Tensor, mat1 *Tensor, mat2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAddmm_

func (ts *Tensor) MustAddmm_(mat1 *Tensor, mat2 *Tensor)

func (*Tensor) MustAddmv

func (ts *Tensor) MustAddmv(mat *Tensor, vec *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAddmvOut

func (ts *Tensor) MustAddmvOut(out *Tensor, mat *Tensor, vec *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAddmv_

func (ts *Tensor) MustAddmv_(mat *Tensor, vec *Tensor)

func (*Tensor) MustAddr

func (ts *Tensor) MustAddr(vec1 *Tensor, vec2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAddrOut

func (ts *Tensor) MustAddrOut(out *Tensor, vec1 *Tensor, vec2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAddr_

func (ts *Tensor) MustAddr_(vec1 *Tensor, vec2 *Tensor)

func (*Tensor) MustAlias

func (ts *Tensor) MustAlias(del bool) (retVal *Tensor)

func (*Tensor) MustAlignAs

func (ts *Tensor) MustAlignAs(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAll

func (ts *Tensor) MustAll(del bool) (retVal *Tensor)

func (*Tensor) MustAll1

func (ts *Tensor) MustAll1(dim int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustAllOut

func (ts *Tensor) MustAllOut(out *Tensor, dim int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustAlphaDropout_

func (ts *Tensor) MustAlphaDropout_(p float64, train bool)

func (*Tensor) MustAmax added in v0.3.0

func (ts *Tensor) MustAmax(dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustAmaxOut added in v0.3.0

func (ts *Tensor) MustAmaxOut(out *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustAmin added in v0.3.0

func (ts *Tensor) MustAmin(dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustAminOut added in v0.3.0

func (ts *Tensor) MustAminOut(out *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustAngle

func (ts *Tensor) MustAngle(del bool) (retVal *Tensor)

func (*Tensor) MustAngleOut

func (ts *Tensor) MustAngleOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAny

func (ts *Tensor) MustAny(del bool) (retVal *Tensor)

func (*Tensor) MustAny1

func (ts *Tensor) MustAny1(dim int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustAnyOut

func (ts *Tensor) MustAnyOut(out *Tensor, dim int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustArccos added in v0.3.0

func (ts *Tensor) MustArccos(del bool) (retVal *Tensor)

func (*Tensor) MustArccosOut added in v0.3.0

func (ts *Tensor) MustArccosOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustArccos_ added in v0.3.0

func (ts *Tensor) MustArccos_()

func (*Tensor) MustArccosh added in v0.3.0

func (ts *Tensor) MustArccosh(del bool) (retVal *Tensor)

func (*Tensor) MustArccoshOut added in v0.3.0

func (ts *Tensor) MustArccoshOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustArccosh_ added in v0.3.0

func (ts *Tensor) MustArccosh_()

func (*Tensor) MustArcsin added in v0.3.0

func (ts *Tensor) MustArcsin(del bool) (retVal *Tensor)

func (*Tensor) MustArcsinOut added in v0.3.0

func (ts *Tensor) MustArcsinOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustArcsin_ added in v0.3.0

func (ts *Tensor) MustArcsin_()

func (*Tensor) MustArcsinh added in v0.3.0

func (ts *Tensor) MustArcsinh(del bool) (retVal *Tensor)

func (*Tensor) MustArcsinhOut added in v0.3.0

func (ts *Tensor) MustArcsinhOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustArcsinh_ added in v0.3.0

func (ts *Tensor) MustArcsinh_()

func (*Tensor) MustArctan added in v0.3.0

func (ts *Tensor) MustArctan(del bool) (retVal *Tensor)

func (*Tensor) MustArctanOut added in v0.3.0

func (ts *Tensor) MustArctanOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustArctan_ added in v0.3.0

func (ts *Tensor) MustArctan_()

func (*Tensor) MustArctanh added in v0.3.0

func (ts *Tensor) MustArctanh(del bool) (retVal *Tensor)

func (*Tensor) MustArctanhOut added in v0.3.0

func (ts *Tensor) MustArctanhOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustArctanh_ added in v0.3.0

func (ts *Tensor) MustArctanh_()

func (*Tensor) MustArgmax

func (ts *Tensor) MustArgmax(dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustArgmin

func (ts *Tensor) MustArgmin(dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustArgsort

func (ts *Tensor) MustArgsort(dim int64, descending bool, del bool) (retVal *Tensor)

func (*Tensor) MustAsStrided

func (ts *Tensor) MustAsStrided(size []int64, stride []int64, storageOffset []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAsStrided_

func (ts *Tensor) MustAsStrided_(size []int64, stride []int64, storageOffset []int64)

func (*Tensor) MustAsin

func (ts *Tensor) MustAsin(del bool) (retVal *Tensor)

func (*Tensor) MustAsinOut

func (ts *Tensor) MustAsinOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAsin_

func (ts *Tensor) MustAsin_()

func (*Tensor) MustAsinh added in v0.3.0

func (ts *Tensor) MustAsinh(del bool) (retVal *Tensor)

func (*Tensor) MustAsinhOut added in v0.3.0

func (ts *Tensor) MustAsinhOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAsinh_ added in v0.3.0

func (ts *Tensor) MustAsinh_()

func (*Tensor) MustAtan

func (ts *Tensor) MustAtan(del bool) (retVal *Tensor)

func (*Tensor) MustAtan2

func (ts *Tensor) MustAtan2(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAtan2Out

func (ts *Tensor) MustAtan2Out(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAtan2_

func (ts *Tensor) MustAtan2_(other *Tensor)

func (*Tensor) MustAtanOut

func (ts *Tensor) MustAtanOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAtan_

func (ts *Tensor) MustAtan_()

func (*Tensor) MustAtanh added in v0.3.0

func (ts *Tensor) MustAtanh(del bool) (retVal *Tensor)

func (*Tensor) MustAtanhOut added in v0.3.0

func (ts *Tensor) MustAtanhOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustAtanh_ added in v0.3.0

func (ts *Tensor) MustAtanh_()

func (*Tensor) MustAtleast1d added in v0.3.0

func (ts *Tensor) MustAtleast1d(del bool) (retVal *Tensor)

func (*Tensor) MustAtleast2d added in v0.3.0

func (ts *Tensor) MustAtleast2d(del bool) (retVal *Tensor)

func (*Tensor) MustAtleast3d added in v0.3.0

func (ts *Tensor) MustAtleast3d(del bool) (retVal *Tensor)

func (*Tensor) MustAvgPool1d

func (ts *Tensor) MustAvgPool1d(kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, del bool) (retVal *Tensor)

func (*Tensor) MustAvgPool2d

func (ts *Tensor) MustAvgPool2d(kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAvgPool2dBackward

func (ts *Tensor) MustAvgPool2dBackward(gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAvgPool2dBackwardOut

func (ts *Tensor) MustAvgPool2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAvgPool2dOut

func (ts *Tensor) MustAvgPool2dOut(out *Tensor, kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAvgPool3d

func (ts *Tensor) MustAvgPool3d(kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAvgPool3dBackward

func (ts *Tensor) MustAvgPool3dBackward(gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAvgPool3dBackwardOut

func (ts *Tensor) MustAvgPool3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor)

func (*Tensor) MustAvgPool3dOut

func (ts *Tensor) MustAvgPool3dOut(out *Tensor, kernelSize []int64, stride []int64, padding []int64, ceilMode bool, countIncludePad bool, divisorOverride []int64, del bool) (retVal *Tensor)

func (*Tensor) MustBackward

func (ts *Tensor) MustBackward()

func (*Tensor) MustBaddbmm

func (ts *Tensor) MustBaddbmm(batch1 *Tensor, batch2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustBaddbmmOut

func (ts *Tensor) MustBaddbmmOut(out *Tensor, batch1 *Tensor, batch2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustBaddbmm_

func (ts *Tensor) MustBaddbmm_(batch1 *Tensor, batch2 *Tensor)

func (*Tensor) MustBernoulli

func (ts *Tensor) MustBernoulli(del bool) (retVal *Tensor)

func (*Tensor) MustBernoulli1

func (ts *Tensor) MustBernoulli1(p float64, del bool) (retVal *Tensor)

func (*Tensor) MustBernoulli1_

func (ts *Tensor) MustBernoulli1_(p float64)

func (*Tensor) MustBernoulliOut

func (ts *Tensor) MustBernoulliOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustBernoulli_

func (ts *Tensor) MustBernoulli_(p *Tensor)

func (*Tensor) MustBinaryCrossEntropy

func (ts *Tensor) MustBinaryCrossEntropy(target *Tensor, weight *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustBinaryCrossEntropyBackward

func (ts *Tensor) MustBinaryCrossEntropyBackward(gradOutput *Tensor, target *Tensor, weight *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustBinaryCrossEntropyBackwardOut

func (ts *Tensor) MustBinaryCrossEntropyBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, weight *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustBinaryCrossEntropyOut

func (ts *Tensor) MustBinaryCrossEntropyOut(out *Tensor, target *Tensor, weight *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustBinaryCrossEntropyWithLogits

func (ts *Tensor) MustBinaryCrossEntropyWithLogits(target *Tensor, weight *Tensor, posWeight *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustBinaryCrossEntropyWithLogitsBackward

func (ts *Tensor) MustBinaryCrossEntropyWithLogitsBackward(gradOutput *Tensor, target *Tensor, weight *Tensor, posWeight *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustBincount

func (ts *Tensor) MustBincount(weights *Tensor, minlength int64, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseAnd

func (ts *Tensor) MustBitwiseAnd(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseAnd1

func (ts *Tensor) MustBitwiseAnd1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseAnd1_

func (ts *Tensor) MustBitwiseAnd1_(other *Tensor)

func (*Tensor) MustBitwiseAndOut

func (ts *Tensor) MustBitwiseAndOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseAndOut1

func (ts *Tensor) MustBitwiseAndOut1(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseAnd_

func (ts *Tensor) MustBitwiseAnd_(other *Scalar)

func (*Tensor) MustBitwiseNot

func (ts *Tensor) MustBitwiseNot(del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseNotOut

func (ts *Tensor) MustBitwiseNotOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseNot_

func (ts *Tensor) MustBitwiseNot_()

func (*Tensor) MustBitwiseOr

func (ts *Tensor) MustBitwiseOr(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseOr1

func (ts *Tensor) MustBitwiseOr1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseOr1_

func (ts *Tensor) MustBitwiseOr1_(other *Tensor)

func (*Tensor) MustBitwiseOrOut

func (ts *Tensor) MustBitwiseOrOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseOrOut1

func (ts *Tensor) MustBitwiseOrOut1(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseOr_

func (ts *Tensor) MustBitwiseOr_(other *Scalar)

func (*Tensor) MustBitwiseXor

func (ts *Tensor) MustBitwiseXor(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseXor1

func (ts *Tensor) MustBitwiseXor1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseXor1_

func (ts *Tensor) MustBitwiseXor1_(other *Tensor)

func (*Tensor) MustBitwiseXorOut

func (ts *Tensor) MustBitwiseXorOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseXorOut1

func (ts *Tensor) MustBitwiseXorOut1(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustBitwiseXor_

func (ts *Tensor) MustBitwiseXor_(other *Scalar)

func (*Tensor) MustBmm

func (ts *Tensor) MustBmm(mat2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustBmmOut

func (ts *Tensor) MustBmmOut(out *Tensor, mat2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustBucketize added in v0.3.0

func (ts *Tensor) MustBucketize(boundaries *Tensor, outInt32 bool, right bool, del bool) (retVal *Tensor)

func (*Tensor) MustBucketizeOut added in v0.3.0

func (ts *Tensor) MustBucketizeOut(out *Tensor, boundaries *Tensor, outInt32 bool, right bool, del bool) (retVal *Tensor)

func (*Tensor) MustCauchy_

func (ts *Tensor) MustCauchy_(median float64, sigma float64)

func (*Tensor) MustCeil

func (ts *Tensor) MustCeil(del bool) (retVal *Tensor)

func (*Tensor) MustCeilOut

func (ts *Tensor) MustCeilOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustCeil_

func (ts *Tensor) MustCeil_()

func (*Tensor) MustCelu

func (ts *Tensor) MustCelu(del bool) (retVal *Tensor)

func (*Tensor) MustCelu_

func (ts *Tensor) MustCelu_()

func (*Tensor) MustChannelShuffle added in v0.3.0

func (ts *Tensor) MustChannelShuffle(groups int64, del bool) (retVal *Tensor)

func (*Tensor) MustCholesky

func (ts *Tensor) MustCholesky(upper bool, del bool) (retVal *Tensor)

func (*Tensor) MustCholeskyInverse

func (ts *Tensor) MustCholeskyInverse(upper bool, del bool) (retVal *Tensor)

func (*Tensor) MustCholeskyInverseOut

func (ts *Tensor) MustCholeskyInverseOut(out *Tensor, upper bool, del bool) (retVal *Tensor)

func (*Tensor) MustCholeskyOut

func (ts *Tensor) MustCholeskyOut(out *Tensor, upper bool, del bool) (retVal *Tensor)

func (*Tensor) MustCholeskySolve

func (ts *Tensor) MustCholeskySolve(input2 *Tensor, upper bool, del bool) (retVal *Tensor)

func (*Tensor) MustCholeskySolveOut

func (ts *Tensor) MustCholeskySolveOut(out *Tensor, input2 *Tensor, upper bool, del bool) (retVal *Tensor)

func (*Tensor) MustChunk

func (ts *Tensor) MustChunk(chunks int64, dim int64, del bool) (retVal []Tensor)

func (*Tensor) MustClamp

func (ts *Tensor) MustClamp(min *Scalar, max *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustClampMax

func (ts *Tensor) MustClampMax(max *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustClampMaxOut

func (ts *Tensor) MustClampMaxOut(out *Tensor, max *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustClampMax_

func (ts *Tensor) MustClampMax_(max *Scalar)

func (*Tensor) MustClampMin

func (ts *Tensor) MustClampMin(min *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustClampMinOut

func (ts *Tensor) MustClampMinOut(out *Tensor, min *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustClampMin_

func (ts *Tensor) MustClampMin_(min *Scalar)

func (*Tensor) MustClampOut

func (ts *Tensor) MustClampOut(out *Tensor, min *Scalar, max *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustClamp_

func (ts *Tensor) MustClamp_(min *Scalar, max *Scalar)

func (*Tensor) MustClip added in v0.3.0

func (ts *Tensor) MustClip(min *Scalar, max *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustClipOut added in v0.3.0

func (ts *Tensor) MustClipOut(out *Tensor, min *Scalar, max *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustClip_ added in v0.3.0

func (ts *Tensor) MustClip_(min *Scalar, max *Scalar)

func (*Tensor) MustCoalesce

func (ts *Tensor) MustCoalesce(del bool) (retVal *Tensor)

func (*Tensor) MustCol2im

func (ts *Tensor) MustCol2im(outputSize []int64, kernelSize []int64, dilation []int64, padding []int64, stride []int64, del bool) (retVal *Tensor)

func (*Tensor) MustCol2imOut

func (ts *Tensor) MustCol2imOut(out *Tensor, outputSize []int64, kernelSize []int64, dilation []int64, padding []int64, stride []int64, del bool) (retVal *Tensor)

func (*Tensor) MustCombinations

func (ts *Tensor) MustCombinations(r int64, withReplacement bool, del bool) (retVal *Tensor)

func (*Tensor) MustConj

func (ts *Tensor) MustConj(del bool) (retVal *Tensor)

func (*Tensor) MustConjOut

func (ts *Tensor) MustConjOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustConstantPadNd

func (ts *Tensor) MustConstantPadNd(pad []int64, del bool) (retVal *Tensor)

func (*Tensor) MustContiguous

func (ts *Tensor) MustContiguous(del bool) (retVal *Tensor)

func (*Tensor) MustConvTbc

func (ts *Tensor) MustConvTbc(weight *Tensor, bias *Tensor, pad int64, del bool) (retVal *Tensor)

func (*Tensor) MustCopyData

func (ts *Tensor) MustCopyData(dst interface{}, numel uint)

MustCopyData copies number of elements from tensor to a slice of data

NOTE: `dst` is a slice with length = numel and Go type equavalent to tensor DType

func (*Tensor) MustCopyDataUint8

func (ts *Tensor) MustCopyDataUint8(dst []uint8, numel uint)

func (*Tensor) MustCopySparseToSparse_

func (ts *Tensor) MustCopySparseToSparse_(src *Tensor, nonBlocking bool)

func (*Tensor) MustCos

func (ts *Tensor) MustCos(del bool) (retVal *Tensor)

func (*Tensor) MustCosOut

func (ts *Tensor) MustCosOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustCos_

func (ts *Tensor) MustCos_()

func (*Tensor) MustCosh

func (ts *Tensor) MustCosh(del bool) (retVal *Tensor)

func (*Tensor) MustCoshOut

func (ts *Tensor) MustCoshOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustCosh_

func (ts *Tensor) MustCosh_()

func (*Tensor) MustCountNonzero added in v0.3.0

func (ts *Tensor) MustCountNonzero(dim []int64, del bool) (retVal *Tensor)

func (*Tensor) MustCountNonzero1 added in v0.3.0

func (ts *Tensor) MustCountNonzero1(dim []int64, del bool) (retVal *Tensor)

func (*Tensor) MustCross

func (ts *Tensor) MustCross(other *Tensor, dim []int64, del bool) (retVal *Tensor)

func (*Tensor) MustCrossOut

func (ts *Tensor) MustCrossOut(out *Tensor, other *Tensor, dim []int64, del bool) (retVal *Tensor)

func (*Tensor) MustCudnnConvolution

func (ts *Tensor) MustCudnnConvolution(weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor)

func (*Tensor) MustCudnnConvolution1

func (ts *Tensor) MustCudnnConvolution1(weight *Tensor, bias *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor)

func (*Tensor) MustCudnnConvolution2 added in v0.3.0

func (ts *Tensor) MustCudnnConvolution2(weight *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, allowTf32 bool, del bool) (retVal *Tensor)

func (*Tensor) MustCudnnConvolutionBackwardWeight

func (ts *Tensor) MustCudnnConvolutionBackwardWeight(weightSize []int64, gradOutput *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, allowTf32 bool, del bool) (retVal *Tensor)

func (*Tensor) MustCudnnConvolutionTranspose

func (ts *Tensor) MustCudnnConvolutionTranspose(weight *Tensor, padding []int64, outputPadding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor)

func (*Tensor) MustCudnnConvolutionTranspose1

func (ts *Tensor) MustCudnnConvolutionTranspose1(weight *Tensor, bias *Tensor, padding []int64, outputPadding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor)

func (*Tensor) MustCudnnConvolutionTranspose2 added in v0.3.0

func (ts *Tensor) MustCudnnConvolutionTranspose2(weight *Tensor, padding []int64, outputPadding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, allowTf32 bool, del bool) (retVal *Tensor)

func (*Tensor) MustCudnnConvolutionTransposeBackwardWeight

func (ts *Tensor) MustCudnnConvolutionTransposeBackwardWeight(weightSize []int64, gradOutput *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, allowTf32 bool, del bool) (retVal *Tensor)

func (*Tensor) MustCudnnGridSampler

func (ts *Tensor) MustCudnnGridSampler(grid *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustCumprod

func (ts *Tensor) MustCumprod(dim int64, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustCumprodOut

func (ts *Tensor) MustCumprodOut(out *Tensor, dim int64, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustCumsum

func (ts *Tensor) MustCumsum(dim int64, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustCumsumOut

func (ts *Tensor) MustCumsumOut(out *Tensor, dim int64, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustData

func (ts *Tensor) MustData(del bool) (retVal *Tensor)

func (*Tensor) MustDefined

func (ts *Tensor) MustDefined() bool

func (*Tensor) MustDeg2rad added in v0.3.0

func (ts *Tensor) MustDeg2rad(del bool) (retVal *Tensor)

func (*Tensor) MustDeg2radOut added in v0.3.0

func (ts *Tensor) MustDeg2radOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustDeg2rad_ added in v0.3.0

func (ts *Tensor) MustDeg2rad_()

func (*Tensor) MustDequantize

func (ts *Tensor) MustDequantize(del bool) (retVal *Tensor)

func (*Tensor) MustDet

func (ts *Tensor) MustDet(del bool) (retVal *Tensor)

func (*Tensor) MustDetach

func (ts *Tensor) MustDetach(del bool) (retVal *Tensor)

func (*Tensor) MustDetach_

func (ts *Tensor) MustDetach_()

func (*Tensor) MustDevice

func (ts *Tensor) MustDevice() gotch.Device

func (*Tensor) MustDiag

func (ts *Tensor) MustDiag(diagonal int64, del bool) (retVal *Tensor)

func (*Tensor) MustDiagEmbed

func (ts *Tensor) MustDiagEmbed(offset int64, dim1 int64, dim2 int64, del bool) (retVal *Tensor)

func (*Tensor) MustDiagOut

func (ts *Tensor) MustDiagOut(out *Tensor, diagonal int64, del bool) (retVal *Tensor)

func (*Tensor) MustDiagflat

func (ts *Tensor) MustDiagflat(offset int64, del bool) (retVal *Tensor)

func (*Tensor) MustDiagonal

func (ts *Tensor) MustDiagonal(offset int64, dim1 int64, dim2 int64, del bool) (retVal *Tensor)

func (*Tensor) MustDigamma

func (ts *Tensor) MustDigamma(del bool) (retVal *Tensor)

func (*Tensor) MustDigammaOut

func (ts *Tensor) MustDigammaOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustDigamma_

func (ts *Tensor) MustDigamma_()

func (*Tensor) MustDist

func (ts *Tensor) MustDist(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustDiv

func (ts *Tensor) MustDiv(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustDiv1

func (ts *Tensor) MustDiv1(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustDiv1_

func (ts *Tensor) MustDiv1_(other *Scalar)

func (*Tensor) MustDivOut

func (ts *Tensor) MustDivOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustDiv_

func (ts *Tensor) MustDiv_(other *Tensor)

func (*Tensor) MustDivide added in v0.3.0

func (ts *Tensor) MustDivide(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustDivide1 added in v0.3.0

func (ts *Tensor) MustDivide1(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustDivide1_ added in v0.3.0

func (ts *Tensor) MustDivide1_(other *Scalar)

func (*Tensor) MustDivideOut added in v0.3.0

func (ts *Tensor) MustDivideOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustDivide_ added in v0.3.0

func (ts *Tensor) MustDivide_(other *Tensor)

func (*Tensor) MustDot

func (ts *Tensor) MustDot(tensor *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustDotOut

func (ts *Tensor) MustDotOut(out *Tensor, tensor *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustDrop

func (ts *Tensor) MustDrop()

MustDrop drops the tensor. It will be panic if error

func (*Tensor) MustDropout_

func (ts *Tensor) MustDropout_(p float64, train bool)

func (*Tensor) MustElu

func (ts *Tensor) MustElu(del bool) (retVal *Tensor)

func (*Tensor) MustEluOut

func (ts *Tensor) MustEluOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustElu_

func (ts *Tensor) MustElu_()

func (*Tensor) MustEmbeddingRenorm_

func (ts *Tensor) MustEmbeddingRenorm_(indices *Tensor, maxNorm float64, normType float64)

func (*Tensor) MustEmptyLike

func (ts *Tensor) MustEmptyLike(del bool) (retVal *Tensor)

func (*Tensor) MustEq

func (ts *Tensor) MustEq(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustEq1

func (ts *Tensor) MustEq1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustEq1_

func (ts *Tensor) MustEq1_(other *Tensor)

func (*Tensor) MustEqOut

func (ts *Tensor) MustEqOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustEqOut1

func (ts *Tensor) MustEqOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustEq_

func (ts *Tensor) MustEq_(other *Scalar)

func (*Tensor) MustErf

func (ts *Tensor) MustErf(del bool) (retVal *Tensor)

func (*Tensor) MustErfOut

func (ts *Tensor) MustErfOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustErf_

func (ts *Tensor) MustErf_()

func (*Tensor) MustErfc

func (ts *Tensor) MustErfc(del bool) (retVal *Tensor)

func (*Tensor) MustErfcOut

func (ts *Tensor) MustErfcOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustErfc_

func (ts *Tensor) MustErfc_()

func (*Tensor) MustErfinv

func (ts *Tensor) MustErfinv(del bool) (retVal *Tensor)

func (*Tensor) MustErfinvOut

func (ts *Tensor) MustErfinvOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustErfinv_

func (ts *Tensor) MustErfinv_()

func (*Tensor) MustExp

func (ts *Tensor) MustExp(del bool) (retVal *Tensor)

func (*Tensor) MustExp2 added in v0.3.0

func (ts *Tensor) MustExp2(del bool) (retVal *Tensor)

func (*Tensor) MustExp2Out added in v0.3.0

func (ts *Tensor) MustExp2Out(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustExp2_ added in v0.3.0

func (ts *Tensor) MustExp2_()

func (*Tensor) MustExpOut

func (ts *Tensor) MustExpOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustExp_

func (ts *Tensor) MustExp_()

func (*Tensor) MustExpand

func (ts *Tensor) MustExpand(size []int64, implicit bool, del bool) (retVal *Tensor)

func (*Tensor) MustExpandAs

func (ts *Tensor) MustExpandAs(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustExpm1

func (ts *Tensor) MustExpm1(del bool) (retVal *Tensor)

func (*Tensor) MustExpm1Out

func (ts *Tensor) MustExpm1Out(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustExpm1_

func (ts *Tensor) MustExpm1_()

func (*Tensor) MustExponential_

func (ts *Tensor) MustExponential_(lambd float64)

func (*Tensor) MustFakeQuantizePerChannelAffine

func (ts *Tensor) MustFakeQuantizePerChannelAffine(scale *Tensor, zeroPoint *Tensor, axis int64, quantMin int64, quantMax int64, del bool) (retVal *Tensor)

func (*Tensor) MustFakeQuantizePerChannelAffineBackward

func (ts *Tensor) MustFakeQuantizePerChannelAffineBackward(grad *Tensor, scale *Tensor, zeroPoint *Tensor, axis int64, quantMin int64, quantMax int64, del bool) (retVal *Tensor)

func (*Tensor) MustFakeQuantizePerTensorAffine

func (ts *Tensor) MustFakeQuantizePerTensorAffine(scale float64, zeroPoint int64, quantMin int64, quantMax int64, del bool) (retVal *Tensor)

func (*Tensor) MustFakeQuantizePerTensorAffineBackward

func (ts *Tensor) MustFakeQuantizePerTensorAffineBackward(grad *Tensor, scale float64, zeroPoint int64, quantMin int64, quantMax int64, del bool) (retVal *Tensor)

func (*Tensor) MustFeatureAlphaDropout_

func (ts *Tensor) MustFeatureAlphaDropout_(p float64, train bool)

func (*Tensor) MustFeatureDropout_

func (ts *Tensor) MustFeatureDropout_(p float64, train bool)

func (*Tensor) MustFft

func (ts *Tensor) MustFft(signalNdim int64, normalized bool, del bool) (retVal *Tensor)

func (*Tensor) MustFftFft added in v0.3.0

func (ts *Tensor) MustFftFft(n []int64, dim int64, norm string, del bool) (retVal *Tensor)

func (*Tensor) MustFftFftn added in v0.3.0

func (ts *Tensor) MustFftFftn(s []int64, dim []int64, norm string, del bool) (retVal *Tensor)

func (*Tensor) MustFftHfft added in v0.3.0

func (ts *Tensor) MustFftHfft(n []int64, dim int64, norm string, del bool) (retVal *Tensor)

func (*Tensor) MustFftIfft added in v0.3.0

func (ts *Tensor) MustFftIfft(n []int64, dim int64, norm string, del bool) (retVal *Tensor)

func (*Tensor) MustFftIfftn added in v0.3.0

func (ts *Tensor) MustFftIfftn(s []int64, dim []int64, norm string, del bool) (retVal *Tensor)

func (*Tensor) MustFftIhfft added in v0.3.0

func (ts *Tensor) MustFftIhfft(n []int64, dim int64, norm string, del bool) (retVal *Tensor)

func (*Tensor) MustFftIrfft added in v0.3.0

func (ts *Tensor) MustFftIrfft(n []int64, dim int64, norm string, del bool) (retVal *Tensor)

func (*Tensor) MustFftIrfftn added in v0.3.0

func (ts *Tensor) MustFftIrfftn(s []int64, dim []int64, norm string, del bool) (retVal *Tensor)

func (*Tensor) MustFftRfft added in v0.3.0

func (ts *Tensor) MustFftRfft(n []int64, dim int64, norm string, del bool) (retVal *Tensor)

func (*Tensor) MustFftRfftn added in v0.3.0

func (ts *Tensor) MustFftRfftn(s []int64, dim []int64, norm string, del bool) (retVal *Tensor)

func (*Tensor) MustFill1_

func (ts *Tensor) MustFill1_(value *Tensor)

func (*Tensor) MustFillDiagonal_

func (ts *Tensor) MustFillDiagonal_(fillValue *Scalar, wrap bool)

func (*Tensor) MustFill_

func (ts *Tensor) MustFill_(value *Scalar)

func (*Tensor) MustFix added in v0.3.0

func (ts *Tensor) MustFix(del bool) (retVal *Tensor)

func (*Tensor) MustFixOut added in v0.3.0

func (ts *Tensor) MustFixOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustFix_ added in v0.3.0

func (ts *Tensor) MustFix_()

func (*Tensor) MustFlatten

func (ts *Tensor) MustFlatten(startDim int64, endDim int64, del bool) (retVal *Tensor)

func (*Tensor) MustFlip

func (ts *Tensor) MustFlip(dims []int64, del bool) (retVal *Tensor)

func (*Tensor) MustFliplr added in v0.3.0

func (ts *Tensor) MustFliplr(del bool) (retVal *Tensor)

func (*Tensor) MustFlipud added in v0.3.0

func (ts *Tensor) MustFlipud(del bool) (retVal *Tensor)

func (*Tensor) MustFloat64Value

func (ts *Tensor) MustFloat64Value(idx []int64) float64

func (*Tensor) MustFloor

func (ts *Tensor) MustFloor(del bool) (retVal *Tensor)

func (*Tensor) MustFloorDivide

func (ts *Tensor) MustFloorDivide(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustFloorDivide1

func (ts *Tensor) MustFloorDivide1(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustFloorDivide1_

func (ts *Tensor) MustFloorDivide1_(other *Scalar)

func (*Tensor) MustFloorDivideOut

func (ts *Tensor) MustFloorDivideOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustFloorDivide_

func (ts *Tensor) MustFloorDivide_(other *Tensor)

func (*Tensor) MustFloorOut

func (ts *Tensor) MustFloorOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustFloor_

func (ts *Tensor) MustFloor_()

func (*Tensor) MustFmod

func (ts *Tensor) MustFmod(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustFmod1

func (ts *Tensor) MustFmod1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustFmod1_

func (ts *Tensor) MustFmod1_(other *Tensor)

func (*Tensor) MustFmodOut

func (ts *Tensor) MustFmodOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustFmodOut1

func (ts *Tensor) MustFmodOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustFmod_

func (ts *Tensor) MustFmod_(other *Scalar)

func (*Tensor) MustFrac

func (ts *Tensor) MustFrac(del bool) (retVal *Tensor)

func (*Tensor) MustFracOut

func (ts *Tensor) MustFracOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustFrac_

func (ts *Tensor) MustFrac_()

func (*Tensor) MustFractionalMaxPool2dBackward

func (ts *Tensor) MustFractionalMaxPool2dBackward(gradOutput *Tensor, kernelSize []int64, outputSize []int64, indices *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustFractionalMaxPool2dBackwardOut

func (ts *Tensor) MustFractionalMaxPool2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, outputSize []int64, indices *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustFractionalMaxPool3dBackward

func (ts *Tensor) MustFractionalMaxPool3dBackward(gradOutput *Tensor, kernelSize []int64, outputSize []int64, indices *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustFractionalMaxPool3dBackwardOut

func (ts *Tensor) MustFractionalMaxPool3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, outputSize []int64, indices *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustFrobeniusNorm

func (ts *Tensor) MustFrobeniusNorm(del bool) (retVal *Tensor)

func (*Tensor) MustFrobeniusNorm1

func (ts *Tensor) MustFrobeniusNorm1(dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustFrobeniusNormOut

func (ts *Tensor) MustFrobeniusNormOut(out *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustFullLike

func (ts *Tensor) MustFullLike(fillValue *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustGather

func (ts *Tensor) MustGather(dim int64, index *Tensor, sparseGrad bool, del bool) (retVal *Tensor)

func (*Tensor) MustGatherBackward added in v0.3.0

func (ts *Tensor) MustGatherBackward(grad *Tensor, dim int64, index *Tensor, sparseGrad bool, del bool) (retVal *Tensor)

func (*Tensor) MustGatherOut

func (ts *Tensor) MustGatherOut(out *Tensor, dim int64, index *Tensor, sparseGrad bool, del bool) (retVal *Tensor)

func (*Tensor) MustGcd added in v0.3.0

func (ts *Tensor) MustGcd(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGcdOut added in v0.3.0

func (ts *Tensor) MustGcdOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGcd_ added in v0.3.0

func (ts *Tensor) MustGcd_(other *Tensor)

func (*Tensor) MustGe

func (ts *Tensor) MustGe(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustGe1

func (ts *Tensor) MustGe1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGe1_

func (ts *Tensor) MustGe1_(other *Tensor)

func (*Tensor) MustGeOut

func (ts *Tensor) MustGeOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustGeOut1

func (ts *Tensor) MustGeOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGe_

func (ts *Tensor) MustGe_(other *Scalar)

func (*Tensor) MustGelu

func (ts *Tensor) MustGelu(del bool) (retVal *Tensor)

func (*Tensor) MustGeluBackward

func (ts *Tensor) MustGeluBackward(grad *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGeometric_

func (ts *Tensor) MustGeometric_(p float64)

func (*Tensor) MustGer

func (ts *Tensor) MustGer(vec2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGerOut

func (ts *Tensor) MustGerOut(out *Tensor, vec2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGet

func (ts *Tensor) MustGet(index int) *Tensor

MustGet gets the sub-tensor at the given index. It will panic if error occurred.

func (*Tensor) MustGlu

func (ts *Tensor) MustGlu(dim int64, del bool) (retVal *Tensor)

func (*Tensor) MustGluBackward

func (ts *Tensor) MustGluBackward(gradOutput *Tensor, dim int64, del bool) (retVal *Tensor)

func (*Tensor) MustGluBackwardOut

func (ts *Tensor) MustGluBackwardOut(gradInput *Tensor, gradOutput *Tensor, dim int64, del bool) (retVal *Tensor)

func (*Tensor) MustGluOut

func (ts *Tensor) MustGluOut(out *Tensor, dim int64, del bool) (retVal *Tensor)

func (*Tensor) MustGrad

func (ts *Tensor) MustGrad(del bool) (retVal *Tensor)

func (*Tensor) MustGreater added in v0.3.0

func (ts *Tensor) MustGreater(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustGreater1 added in v0.3.0

func (ts *Tensor) MustGreater1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGreater1_ added in v0.3.0

func (ts *Tensor) MustGreater1_(other *Tensor)

func (*Tensor) MustGreaterEqual added in v0.3.0

func (ts *Tensor) MustGreaterEqual(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustGreaterEqual1 added in v0.3.0

func (ts *Tensor) MustGreaterEqual1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGreaterEqual1_ added in v0.3.0

func (ts *Tensor) MustGreaterEqual1_(other *Tensor)

func (*Tensor) MustGreaterEqualOut added in v0.3.0

func (ts *Tensor) MustGreaterEqualOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustGreaterEqualOut1 added in v0.3.0

func (ts *Tensor) MustGreaterEqualOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGreaterEqual_ added in v0.3.0

func (ts *Tensor) MustGreaterEqual_(other *Scalar)

func (*Tensor) MustGreaterOut added in v0.3.0

func (ts *Tensor) MustGreaterOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustGreaterOut1 added in v0.3.0

func (ts *Tensor) MustGreaterOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGreater_ added in v0.3.0

func (ts *Tensor) MustGreater_(other *Scalar)

func (*Tensor) MustGru

func (ts *Tensor) MustGru(hx *Tensor, paramsData []Tensor, hasBiases bool, numLayers int64, dropout float64, train bool, bidirectional bool, batchFirst bool) (output, h *Tensor)

func (*Tensor) MustGt

func (ts *Tensor) MustGt(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustGt1

func (ts *Tensor) MustGt1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGt1_

func (ts *Tensor) MustGt1_(other *Tensor)

func (*Tensor) MustGtOut

func (ts *Tensor) MustGtOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustGtOut1

func (ts *Tensor) MustGtOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustGt_

func (ts *Tensor) MustGt_(other *Scalar)

func (*Tensor) MustHardshrink

func (ts *Tensor) MustHardshrink(del bool) (retVal *Tensor)

func (*Tensor) MustHardshrinkBackward

func (ts *Tensor) MustHardshrinkBackward(gradOut *Tensor, lambd *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustHardsigmoid

func (ts *Tensor) MustHardsigmoid(del bool) (retVal *Tensor)

func (*Tensor) MustHardsigmoidBackward

func (ts *Tensor) MustHardsigmoidBackward(gradOutput *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustHardsigmoidOut

func (ts *Tensor) MustHardsigmoidOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustHardsigmoid_

func (ts *Tensor) MustHardsigmoid_()

func (*Tensor) MustHardswish added in v0.3.0

func (ts *Tensor) MustHardswish(del bool) (retVal *Tensor)

func (*Tensor) MustHardswishBackward added in v0.3.0

func (ts *Tensor) MustHardswishBackward(gradOutput *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustHardswishOut added in v0.3.0

func (ts *Tensor) MustHardswishOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustHardswish_ added in v0.3.0

func (ts *Tensor) MustHardswish_()

func (*Tensor) MustHardtanh

func (ts *Tensor) MustHardtanh(del bool) (retVal *Tensor)

func (*Tensor) MustHardtanhBackward

func (ts *Tensor) MustHardtanhBackward(gradOutput *Tensor, minVal *Scalar, maxVal *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustHardtanhBackwardOut

func (ts *Tensor) MustHardtanhBackwardOut(gradInput *Tensor, gradOutput *Tensor, minVal *Scalar, maxVal *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustHardtanhOut

func (ts *Tensor) MustHardtanhOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustHardtanh_

func (ts *Tensor) MustHardtanh_()

func (*Tensor) MustHeaviside added in v0.3.0

func (ts *Tensor) MustHeaviside(values *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustHeavisideOut added in v0.3.0

func (ts *Tensor) MustHeavisideOut(out *Tensor, values *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustHeaviside_ added in v0.3.0

func (ts *Tensor) MustHeaviside_(values *Tensor)

func (*Tensor) MustHingeEmbeddingLoss

func (ts *Tensor) MustHingeEmbeddingLoss(target *Tensor, margin float64, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustHistc

func (ts *Tensor) MustHistc(bins int64, del bool) (retVal *Tensor)

func (*Tensor) MustHistcOut

func (ts *Tensor) MustHistcOut(out *Tensor, bins int64, del bool) (retVal *Tensor)

func (*Tensor) MustHypot added in v0.3.0

func (ts *Tensor) MustHypot(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustHypotOut added in v0.3.0

func (ts *Tensor) MustHypotOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustHypot_ added in v0.3.0

func (ts *Tensor) MustHypot_(other *Tensor)

func (*Tensor) MustI0 added in v0.3.0

func (ts *Tensor) MustI0(del bool) (retVal *Tensor)

func (*Tensor) MustI0Out added in v0.3.0

func (ts *Tensor) MustI0Out(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustI0_ added in v0.3.0

func (ts *Tensor) MustI0_()

func (*Tensor) MustIfft

func (ts *Tensor) MustIfft(signalNdim int64, normalized bool, del bool) (retVal *Tensor)

func (*Tensor) MustIm2col

func (ts *Tensor) MustIm2col(kernelSize []int64, dilation []int64, padding []int64, stride []int64, del bool) (retVal *Tensor)

func (*Tensor) MustIm2colOut

func (ts *Tensor) MustIm2colOut(out *Tensor, kernelSize []int64, dilation []int64, padding []int64, stride []int64, del bool) (retVal *Tensor)

func (*Tensor) MustImag

func (ts *Tensor) MustImag(del bool) (retVal *Tensor)

func (*Tensor) MustIndex

func (ts *Tensor) MustIndex(indices []Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustIndexAdd

func (ts *Tensor) MustIndexAdd(dim int64, index *Tensor, source *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustIndexAdd_

func (ts *Tensor) MustIndexAdd_(dim int64, index *Tensor, source *Tensor)

func (*Tensor) MustIndexCopy

func (ts *Tensor) MustIndexCopy(dim int64, index *Tensor, source *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustIndexCopy_

func (ts *Tensor) MustIndexCopy_(dim int64, index *Tensor, source *Tensor)

func (*Tensor) MustIndexFill

func (ts *Tensor) MustIndexFill(dim int64, index *Tensor, value *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustIndexFill1

func (ts *Tensor) MustIndexFill1(dim int64, index *Tensor, value *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustIndexFill1_

func (ts *Tensor) MustIndexFill1_(dim int64, index *Tensor, value *Tensor)

func (*Tensor) MustIndexFill_

func (ts *Tensor) MustIndexFill_(dim int64, index *Tensor, value *Scalar)

func (*Tensor) MustIndexPut

func (ts *Tensor) MustIndexPut(indices []Tensor, values *Tensor, accumulate bool, del bool) (retVal *Tensor)

func (*Tensor) MustIndexPut_

func (ts *Tensor) MustIndexPut_(indices []Tensor, values *Tensor, accumulate bool)

func (*Tensor) MustIndexSelect

func (ts *Tensor) MustIndexSelect(dim int64, index *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustIndexSelectOut

func (ts *Tensor) MustIndexSelectOut(out *Tensor, dim int64, index *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustIndices

func (ts *Tensor) MustIndices(del bool) (retVal *Tensor)

func (*Tensor) MustInfinitelyDifferentiableGeluBackward added in v0.3.0

func (ts *Tensor) MustInfinitelyDifferentiableGeluBackward(grad *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustInt64Value

func (ts *Tensor) MustInt64Value(idx []int64) int64

func (*Tensor) MustIntRepr

func (ts *Tensor) MustIntRepr(del bool) (retVal *Tensor)

func (*Tensor) MustInverse

func (ts *Tensor) MustInverse(del bool) (retVal *Tensor)

func (*Tensor) MustInverseOut

func (ts *Tensor) MustInverseOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustIrfft

func (ts *Tensor) MustIrfft(signalNdim int64, normalized bool, onesided bool, signalSizes []int64, del bool) (retVal *Tensor)

func (*Tensor) MustIsclose

func (ts *Tensor) MustIsclose(other *Tensor, rtol float64, atol float64, equalNan bool, del bool) (retVal *Tensor)

func (*Tensor) MustIsfinite

func (ts *Tensor) MustIsfinite(del bool) (retVal *Tensor)

func (*Tensor) MustIsinf

func (ts *Tensor) MustIsinf(del bool) (retVal *Tensor)

func (*Tensor) MustIsnan

func (ts *Tensor) MustIsnan(del bool) (retVal *Tensor)

func (*Tensor) MustIsneginf added in v0.3.0

func (ts *Tensor) MustIsneginf(del bool) (retVal *Tensor)

func (*Tensor) MustIsneginfOut added in v0.3.0

func (ts *Tensor) MustIsneginfOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustIsposinf added in v0.3.0

func (ts *Tensor) MustIsposinf(del bool) (retVal *Tensor)

func (*Tensor) MustIsposinfOut added in v0.3.0

func (ts *Tensor) MustIsposinfOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustIsreal added in v0.3.0

func (ts *Tensor) MustIsreal(del bool) (retVal *Tensor)

func (*Tensor) MustIstft added in v0.3.0

func (ts *Tensor) MustIstft(nFft int64, hopLength []int64, winLength []int64, window *Tensor, center bool, normalized bool, onesided bool, length []int64, returnComplex bool, del bool) (retVal *Tensor)

func (*Tensor) MustKlDiv

func (ts *Tensor) MustKlDiv(target *Tensor, reduction int64, logTarget bool, del bool) (retVal *Tensor)

func (*Tensor) MustKlDivBackward

func (ts *Tensor) MustKlDivBackward(gradOutput *Tensor, target *Tensor, reduction int64, logTarget bool, del bool) (retVal *Tensor)

func (*Tensor) MustL1Loss

func (ts *Tensor) MustL1Loss(target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustL1LossBackward

func (ts *Tensor) MustL1LossBackward(gradOutput *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustL1LossBackwardOut

func (ts *Tensor) MustL1LossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustL1LossOut

func (ts *Tensor) MustL1LossOut(out *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustLcm added in v0.3.0

func (ts *Tensor) MustLcm(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLcmOut added in v0.3.0

func (ts *Tensor) MustLcmOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLcm_ added in v0.3.0

func (ts *Tensor) MustLcm_(other *Tensor)

func (*Tensor) MustLe

func (ts *Tensor) MustLe(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustLe1

func (ts *Tensor) MustLe1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLe1_

func (ts *Tensor) MustLe1_(other *Tensor)

func (*Tensor) MustLeOut

func (ts *Tensor) MustLeOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustLeOut1

func (ts *Tensor) MustLeOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLe_

func (ts *Tensor) MustLe_(other *Scalar)

func (*Tensor) MustLeakyRelu

func (ts *Tensor) MustLeakyRelu(del bool) (retVal *Tensor)

func (*Tensor) MustLeakyReluBackward

func (ts *Tensor) MustLeakyReluBackward(gradOutput *Tensor, negativeSlope *Scalar, selfIsResult bool, del bool) (retVal *Tensor)

func (*Tensor) MustLeakyReluOut

func (ts *Tensor) MustLeakyReluOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLeakyRelu_

func (ts *Tensor) MustLeakyRelu_()

func (*Tensor) MustLerp

func (ts *Tensor) MustLerp(end *Tensor, weight *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustLerp1

func (ts *Tensor) MustLerp1(end *Tensor, weight *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLerp1_

func (ts *Tensor) MustLerp1_(end *Tensor, weight *Tensor)

func (*Tensor) MustLerpOut

func (ts *Tensor) MustLerpOut(out *Tensor, end *Tensor, weight *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustLerpOut1

func (ts *Tensor) MustLerpOut1(out *Tensor, end *Tensor, weight *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLerp_

func (ts *Tensor) MustLerp_(end *Tensor, weight *Scalar)

func (*Tensor) MustLess added in v0.3.0

func (ts *Tensor) MustLess(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustLess1 added in v0.3.0

func (ts *Tensor) MustLess1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLess1_ added in v0.3.0

func (ts *Tensor) MustLess1_(other *Tensor)

func (*Tensor) MustLessEqual added in v0.3.0

func (ts *Tensor) MustLessEqual(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustLessEqual1 added in v0.3.0

func (ts *Tensor) MustLessEqual1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLessEqual1_ added in v0.3.0

func (ts *Tensor) MustLessEqual1_(other *Tensor)

func (*Tensor) MustLessEqualOut added in v0.3.0

func (ts *Tensor) MustLessEqualOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustLessEqualOut1 added in v0.3.0

func (ts *Tensor) MustLessEqualOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLessEqual_ added in v0.3.0

func (ts *Tensor) MustLessEqual_(other *Scalar)

func (*Tensor) MustLessOut added in v0.3.0

func (ts *Tensor) MustLessOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustLessOut1 added in v0.3.0

func (ts *Tensor) MustLessOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLess_ added in v0.3.0

func (ts *Tensor) MustLess_(other *Scalar)

func (*Tensor) MustLgamma

func (ts *Tensor) MustLgamma(del bool) (retVal *Tensor)

func (*Tensor) MustLgammaOut

func (ts *Tensor) MustLgammaOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLgamma_

func (ts *Tensor) MustLgamma_()

func (*Tensor) MustLinalgDet added in v0.3.0

func (ts *Tensor) MustLinalgDet(del bool) (retVal *Tensor)

func (*Tensor) MustLinalgNorm added in v0.3.0

func (ts *Tensor) MustLinalgNorm(ord *Scalar, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustLinalgNorm1 added in v0.3.0

func (ts *Tensor) MustLinalgNorm1(ord string, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustLinalgNormOut added in v0.3.0

func (ts *Tensor) MustLinalgNormOut(out *Tensor, ord *Scalar, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustLinalgNormOut1 added in v0.3.0

func (ts *Tensor) MustLinalgNormOut1(out *Tensor, ord string, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustLog

func (ts *Tensor) MustLog(del bool) (retVal *Tensor)

func (*Tensor) MustLog10

func (ts *Tensor) MustLog10(del bool) (retVal *Tensor)

func (*Tensor) MustLog10Out

func (ts *Tensor) MustLog10Out(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLog10_

func (ts *Tensor) MustLog10_()

func (*Tensor) MustLog1p

func (ts *Tensor) MustLog1p(del bool) (retVal *Tensor)

func (*Tensor) MustLog1pOut

func (ts *Tensor) MustLog1pOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLog1p_

func (ts *Tensor) MustLog1p_()

func (*Tensor) MustLog2

func (ts *Tensor) MustLog2(del bool) (retVal *Tensor)

func (*Tensor) MustLog2Out

func (ts *Tensor) MustLog2Out(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLog2_

func (ts *Tensor) MustLog2_()

func (*Tensor) MustLogNormal_

func (ts *Tensor) MustLogNormal_(mean float64, std float64)

func (*Tensor) MustLogOut

func (ts *Tensor) MustLogOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogSigmoid

func (ts *Tensor) MustLogSigmoid(del bool) (retVal *Tensor)

func (*Tensor) MustLogSigmoidBackward

func (ts *Tensor) MustLogSigmoidBackward(gradOutput *Tensor, buffer *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogSigmoidBackwardOut

func (ts *Tensor) MustLogSigmoidBackwardOut(gradInput *Tensor, gradOutput *Tensor, buffer *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogSigmoidOut

func (ts *Tensor) MustLogSigmoidOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogSoftmax

func (ts *Tensor) MustLogSoftmax(dim int64, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustLog_

func (ts *Tensor) MustLog_()

func (*Tensor) MustLogaddexp added in v0.3.0

func (ts *Tensor) MustLogaddexp(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogaddexp2 added in v0.3.0

func (ts *Tensor) MustLogaddexp2(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogaddexp2Out added in v0.3.0

func (ts *Tensor) MustLogaddexp2Out(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogaddexpOut added in v0.3.0

func (ts *Tensor) MustLogaddexpOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogcumsumexp added in v0.3.0

func (ts *Tensor) MustLogcumsumexp(dim int64, del bool) (retVal *Tensor)

func (*Tensor) MustLogcumsumexpOut added in v0.3.0

func (ts *Tensor) MustLogcumsumexpOut(out *Tensor, dim int64, del bool) (retVal *Tensor)

func (*Tensor) MustLogdet

func (ts *Tensor) MustLogdet(del bool) (retVal *Tensor)

func (*Tensor) MustLogicalAnd

func (ts *Tensor) MustLogicalAnd(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogicalAndOut

func (ts *Tensor) MustLogicalAndOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogicalAnd_

func (ts *Tensor) MustLogicalAnd_(other *Tensor)

func (*Tensor) MustLogicalNot

func (ts *Tensor) MustLogicalNot(del bool) (retVal *Tensor)

func (*Tensor) MustLogicalNotOut

func (ts *Tensor) MustLogicalNotOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogicalNot_

func (ts *Tensor) MustLogicalNot_()

func (*Tensor) MustLogicalOr

func (ts *Tensor) MustLogicalOr(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogicalOrOut

func (ts *Tensor) MustLogicalOrOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogicalOr_

func (ts *Tensor) MustLogicalOr_(other *Tensor)

func (*Tensor) MustLogicalXor

func (ts *Tensor) MustLogicalXor(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogicalXorOut

func (ts *Tensor) MustLogicalXorOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLogicalXor_

func (ts *Tensor) MustLogicalXor_(other *Tensor)

func (*Tensor) MustLogit added in v0.3.0

func (ts *Tensor) MustLogit(eps []float64, del bool) (retVal *Tensor)

func (*Tensor) MustLogitBackward added in v0.3.0

func (ts *Tensor) MustLogitBackward(gradOutput *Tensor, eps []float64, del bool) (retVal *Tensor)

func (*Tensor) MustLogitBackwardOut added in v0.3.0

func (ts *Tensor) MustLogitBackwardOut(gradInput *Tensor, gradOutput *Tensor, eps []float64, del bool) (retVal *Tensor)

func (*Tensor) MustLogitOut added in v0.3.0

func (ts *Tensor) MustLogitOut(out *Tensor, eps []float64, del bool) (retVal *Tensor)

func (*Tensor) MustLogit_ added in v0.3.0

func (ts *Tensor) MustLogit_(eps []float64)

func (*Tensor) MustLogsumexp

func (ts *Tensor) MustLogsumexp(dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustLogsumexpOut

func (ts *Tensor) MustLogsumexpOut(out *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustLstm

func (ts *Tensor) MustLstm(hxData []Tensor, paramsData []Tensor, hasBiases bool, numLayers int64, dropout float64, train bool, bidirectional bool, batchFirst bool) (output, h, c *Tensor)

func (*Tensor) MustLstsq added in v0.3.9

func (ts *Tensor) MustLstsq(a *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLt

func (ts *Tensor) MustLt(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustLt1

func (ts *Tensor) MustLt1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLt1_

func (ts *Tensor) MustLt1_(other *Tensor)

func (*Tensor) MustLtOut

func (ts *Tensor) MustLtOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustLtOut1

func (ts *Tensor) MustLtOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLt_

func (ts *Tensor) MustLt_(other *Scalar)

func (*Tensor) MustLuSolve

func (ts *Tensor) MustLuSolve(lUData *Tensor, lUPivots *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustLuSolveOut

func (ts *Tensor) MustLuSolveOut(out *Tensor, lUData *Tensor, lUPivots *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMaskedFill

func (ts *Tensor) MustMaskedFill(mask *Tensor, value *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustMaskedFill1

func (ts *Tensor) MustMaskedFill1(mask *Tensor, value *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMaskedFill1_

func (ts *Tensor) MustMaskedFill1_(mask *Tensor, value *Tensor)

func (*Tensor) MustMaskedFill_

func (ts *Tensor) MustMaskedFill_(mask *Tensor, value *Scalar)

func (*Tensor) MustMaskedScatter

func (ts *Tensor) MustMaskedScatter(mask *Tensor, source *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMaskedScatter_

func (ts *Tensor) MustMaskedScatter_(mask *Tensor, source *Tensor)

func (*Tensor) MustMaskedSelect

func (ts *Tensor) MustMaskedSelect(mask *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMaskedSelectOut

func (ts *Tensor) MustMaskedSelectOut(out *Tensor, mask *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMatmul

func (ts *Tensor) MustMatmul(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMatmulOut

func (ts *Tensor) MustMatmulOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMatrixExp added in v0.3.0

func (ts *Tensor) MustMatrixExp(del bool) (retVal *Tensor)

func (*Tensor) MustMatrixExpBackward added in v0.3.0

func (ts *Tensor) MustMatrixExpBackward(grad *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMatrixPower

func (ts *Tensor) MustMatrixPower(n int64, del bool) (retVal *Tensor)

func (*Tensor) MustMatrixRank

func (ts *Tensor) MustMatrixRank(symmetric bool, del bool) (retVal *Tensor)

func (*Tensor) MustMatrixRank1

func (ts *Tensor) MustMatrixRank1(tol float64, symmetric bool, del bool) (retVal *Tensor)

func (*Tensor) MustMax

func (ts *Tensor) MustMax(del bool) (retVal *Tensor)

func (*Tensor) MustMax1

func (ts *Tensor) MustMax1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMaxOut

func (ts *Tensor) MustMaxOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMaxPool1d

func (ts *Tensor) MustMaxPool1d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor)

func (*Tensor) MustMaxPool2d

func (ts *Tensor) MustMaxPool2d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor)

func (*Tensor) MustMaxPool2dWithIndicesBackward

func (ts *Tensor) MustMaxPool2dWithIndicesBackward(gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, indices *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMaxPool2dWithIndicesBackwardOut

func (ts *Tensor) MustMaxPool2dWithIndicesBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, indices *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMaxPool3d

func (ts *Tensor) MustMaxPool3d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor)

func (*Tensor) MustMaxPool3dWithIndicesBackward

func (ts *Tensor) MustMaxPool3dWithIndicesBackward(gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, indices *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMaxPool3dWithIndicesBackwardOut

func (ts *Tensor) MustMaxPool3dWithIndicesBackwardOut(gradInput *Tensor, gradOutput *Tensor, kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, indices *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMaxUnpool2d

func (ts *Tensor) MustMaxUnpool2d(indices *Tensor, outputSize []int64, del bool) (retVal *Tensor)

func (*Tensor) MustMaxUnpool2dBackward

func (ts *Tensor) MustMaxUnpool2dBackward(gradOutput *Tensor, indices *Tensor, outputSize []int64, del bool) (retVal *Tensor)

func (*Tensor) MustMaxUnpool2dBackwardOut

func (ts *Tensor) MustMaxUnpool2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, indices *Tensor, outputSize []int64, del bool) (retVal *Tensor)

func (*Tensor) MustMaxUnpool2dOut

func (ts *Tensor) MustMaxUnpool2dOut(out *Tensor, indices *Tensor, outputSize []int64, del bool) (retVal *Tensor)

func (*Tensor) MustMaxUnpool3d

func (ts *Tensor) MustMaxUnpool3d(indices *Tensor, outputSize []int64, stride []int64, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustMaxUnpool3dBackward

func (ts *Tensor) MustMaxUnpool3dBackward(gradOutput *Tensor, indices *Tensor, outputSize []int64, stride []int64, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustMaxUnpool3dBackwardOut

func (ts *Tensor) MustMaxUnpool3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, indices *Tensor, outputSize []int64, stride []int64, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustMaxUnpool3dOut

func (ts *Tensor) MustMaxUnpool3dOut(out *Tensor, indices *Tensor, outputSize []int64, stride []int64, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustMaximum added in v0.3.0

func (ts *Tensor) MustMaximum(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMaximumOut added in v0.3.0

func (ts *Tensor) MustMaximumOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMean

func (ts *Tensor) MustMean(dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustMean1

func (ts *Tensor) MustMean1(dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustMeanOut

func (ts *Tensor) MustMeanOut(out *Tensor, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustMedian

func (ts *Tensor) MustMedian(del bool) (retVal *Tensor)

func (*Tensor) MustMeshgrid

func (ts *Tensor) MustMeshgrid(tensors []Tensor, del bool) (retVal []Tensor)

func (*Tensor) MustMin

func (ts *Tensor) MustMin(del bool) (retVal *Tensor)

func (*Tensor) MustMin1

func (ts *Tensor) MustMin1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMinOut

func (ts *Tensor) MustMinOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMinimum added in v0.3.0

func (ts *Tensor) MustMinimum(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMinimumOut added in v0.3.0

func (ts *Tensor) MustMinimumOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMiopenConvolution

func (ts *Tensor) MustMiopenConvolution(weight *Tensor, bias *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor)

func (*Tensor) MustMiopenConvolutionBackwardWeight

func (ts *Tensor) MustMiopenConvolutionBackwardWeight(weightSize []int64, gradOutput *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor)

func (*Tensor) MustMiopenConvolutionTranspose

func (ts *Tensor) MustMiopenConvolutionTranspose(weight *Tensor, bias *Tensor, padding []int64, outputPadding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor)

func (*Tensor) MustMiopenConvolutionTransposeBackwardWeight

func (ts *Tensor) MustMiopenConvolutionTransposeBackwardWeight(weightSize []int64, gradOutput *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor)

func (*Tensor) MustMiopenDepthwiseConvolution

func (ts *Tensor) MustMiopenDepthwiseConvolution(weight *Tensor, bias *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor)

func (*Tensor) MustMiopenDepthwiseConvolutionBackwardWeight

func (ts *Tensor) MustMiopenDepthwiseConvolutionBackwardWeight(weightSize []int64, gradOutput *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, benchmark bool, deterministic bool, del bool) (retVal *Tensor)

func (*Tensor) MustMkldnnAdaptiveAvgPool2d

func (ts *Tensor) MustMkldnnAdaptiveAvgPool2d(outputSize []int64, del bool) (retVal *Tensor)

func (*Tensor) MustMkldnnConvolution

func (ts *Tensor) MustMkldnnConvolution(weight *Tensor, bias *Tensor, padding []int64, stride []int64, dilation []int64, groups int64, del bool) (retVal *Tensor)

func (*Tensor) MustMkldnnMaxPool2d

func (ts *Tensor) MustMkldnnMaxPool2d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor)

func (*Tensor) MustMkldnnMaxPool3d added in v0.3.0

func (ts *Tensor) MustMkldnnMaxPool3d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor)

func (*Tensor) MustMkldnnReorderConv2dWeight

func (ts *Tensor) MustMkldnnReorderConv2dWeight(padding []int64, stride []int64, dilation []int64, groups int64, del bool) (retVal *Tensor)

func (*Tensor) MustMkldnnReorderConv3dWeight added in v0.3.0

func (ts *Tensor) MustMkldnnReorderConv3dWeight(padding []int64, stride []int64, dilation []int64, groups int64, del bool) (retVal *Tensor)

func (*Tensor) MustMm

func (ts *Tensor) MustMm(mat2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMmOut

func (ts *Tensor) MustMmOut(out *Tensor, mat2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMovedim added in v0.3.0

func (ts *Tensor) MustMovedim(source []int64, destination []int64, del bool) (retVal *Tensor)

func (*Tensor) MustMovedim1 added in v0.3.0

func (ts *Tensor) MustMovedim1(source int64, destination int64, del bool) (retVal *Tensor)

func (*Tensor) MustMseLoss

func (ts *Tensor) MustMseLoss(target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustMseLossBackward

func (ts *Tensor) MustMseLossBackward(gradOutput *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustMseLossBackwardOut

func (ts *Tensor) MustMseLossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustMseLossOut

func (ts *Tensor) MustMseLossOut(out *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustMul

func (ts *Tensor) MustMul(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMul1

func (ts *Tensor) MustMul1(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustMul1_

func (ts *Tensor) MustMul1_(other *Scalar)

func (*Tensor) MustMulOut

func (ts *Tensor) MustMulOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMul_

func (ts *Tensor) MustMul_(other *Tensor)

func (*Tensor) MustMultiMarginLossBackward

func (ts *Tensor) MustMultiMarginLossBackward(gradOutput *Tensor, target *Tensor, p *Scalar, margin *Scalar, weight *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustMultiMarginLossBackwardOut

func (ts *Tensor) MustMultiMarginLossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, p *Scalar, margin *Scalar, weight *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustMultilabelMarginLoss

func (ts *Tensor) MustMultilabelMarginLoss(target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustMultilabelMarginLossBackward

func (ts *Tensor) MustMultilabelMarginLossBackward(gradOutput *Tensor, target *Tensor, reduction int64, isTarget *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMultilabelMarginLossBackwardOut

func (ts *Tensor) MustMultilabelMarginLossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, reduction int64, isTarget *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMultilabelMarginLossOut

func (ts *Tensor) MustMultilabelMarginLossOut(out *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustMultinomial

func (ts *Tensor) MustMultinomial(numSamples int64, replacement bool, del bool) (retVal *Tensor)

func (*Tensor) MustMultinomialOut

func (ts *Tensor) MustMultinomialOut(out *Tensor, numSamples int64, replacement bool, del bool) (retVal *Tensor)

func (*Tensor) MustMultiply added in v0.3.0

func (ts *Tensor) MustMultiply(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMultiply1 added in v0.3.0

func (ts *Tensor) MustMultiply1(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustMultiply1_ added in v0.3.0

func (ts *Tensor) MustMultiply1_(other *Scalar)

func (*Tensor) MustMultiplyOut added in v0.3.0

func (ts *Tensor) MustMultiplyOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMultiply_ added in v0.3.0

func (ts *Tensor) MustMultiply_(other *Tensor)

func (*Tensor) MustMv

func (ts *Tensor) MustMv(vec *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMvOut

func (ts *Tensor) MustMvOut(out *Tensor, vec *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustMvlgamma

func (ts *Tensor) MustMvlgamma(p int64, del bool) (retVal *Tensor)

func (*Tensor) MustMvlgamma_

func (ts *Tensor) MustMvlgamma_(p int64)

func (*Tensor) MustNLLLoss

func (ts *Tensor) MustNLLLoss(target *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNanquantile added in v0.3.0

func (ts *Tensor) MustNanquantile(q float64, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustNanquantile1 added in v0.3.0

func (ts *Tensor) MustNanquantile1(q *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustNanquantileOut added in v0.3.0

func (ts *Tensor) MustNanquantileOut(out *Tensor, q float64, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustNanquantileOut1 added in v0.3.0

func (ts *Tensor) MustNanquantileOut1(out *Tensor, q *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustNansum added in v0.3.0

func (ts *Tensor) MustNansum(dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustNansum1 added in v0.3.0

func (ts *Tensor) MustNansum1(dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustNansumOut added in v0.3.0

func (ts *Tensor) MustNansumOut(out *Tensor, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustNarrow

func (ts *Tensor) MustNarrow(dim int64, start int64, length int64, del bool) (retVal *Tensor)

func (*Tensor) MustNarrow1

func (ts *Tensor) MustNarrow1(dim int64, start *Tensor, length int64, del bool) (retVal *Tensor)

func (*Tensor) MustNarrowCopy

func (ts *Tensor) MustNarrowCopy(dim int64, start int64, length int64, del bool) (retVal *Tensor)

func (*Tensor) MustNativeNorm

func (ts *Tensor) MustNativeNorm(del bool) (retVal *Tensor)

func (*Tensor) MustNativeNorm1 added in v0.3.0

func (ts *Tensor) MustNativeNorm1(p *Scalar, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustNe

func (ts *Tensor) MustNe(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustNe1

func (ts *Tensor) MustNe1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNe1_

func (ts *Tensor) MustNe1_(other *Tensor)

func (*Tensor) MustNeOut

func (ts *Tensor) MustNeOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustNeOut1

func (ts *Tensor) MustNeOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNe_

func (ts *Tensor) MustNe_(other *Scalar)

func (*Tensor) MustNeg

func (ts *Tensor) MustNeg(del bool) (retVal *Tensor)

func (*Tensor) MustNegOut

func (ts *Tensor) MustNegOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNeg_

func (ts *Tensor) MustNeg_()

func (*Tensor) MustNegative added in v0.3.0

func (ts *Tensor) MustNegative(del bool) (retVal *Tensor)

func (*Tensor) MustNegativeOut added in v0.3.0

func (ts *Tensor) MustNegativeOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNegative_ added in v0.3.0

func (ts *Tensor) MustNegative_()

func (*Tensor) MustNewEmpty

func (ts *Tensor) MustNewEmpty(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device, del bool) (retVal *Tensor)

func (*Tensor) MustNewFull

func (ts *Tensor) MustNewFull(size []int64, fillValue *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device, del bool) (retVal *Tensor)

func (*Tensor) MustNewZeros

func (ts *Tensor) MustNewZeros(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device, del bool) (retVal *Tensor)

func (*Tensor) MustNextafter added in v0.3.0

func (ts *Tensor) MustNextafter(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNextafterOut added in v0.3.0

func (ts *Tensor) MustNextafterOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNextafter_ added in v0.3.0

func (ts *Tensor) MustNextafter_(other *Tensor)

func (*Tensor) MustNllLoss

func (ts *Tensor) MustNllLoss(target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, del bool) (retVal *Tensor)

func (*Tensor) MustNllLoss2d

func (ts *Tensor) MustNllLoss2d(target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, del bool) (retVal *Tensor)

func (*Tensor) MustNllLoss2dBackward

func (ts *Tensor) MustNllLoss2dBackward(gradOutput *Tensor, target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, totalWeight *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNllLoss2dBackwardOut

func (ts *Tensor) MustNllLoss2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, totalWeight *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNllLoss2dOut

func (ts *Tensor) MustNllLoss2dOut(out *Tensor, target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, del bool) (retVal *Tensor)

func (*Tensor) MustNllLossBackward

func (ts *Tensor) MustNllLossBackward(gradOutput *Tensor, target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, totalWeight *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNllLossBackwardOut

func (ts *Tensor) MustNllLossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, totalWeight *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNllLossOut

func (ts *Tensor) MustNllLossOut(out *Tensor, target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, del bool) (retVal *Tensor)

func (*Tensor) MustNonzero

func (ts *Tensor) MustNonzero(del bool) (retVal *Tensor)

func (*Tensor) MustNonzeroNumpy

func (ts *Tensor) MustNonzeroNumpy(del bool) (retVal []Tensor)

func (*Tensor) MustNonzeroOut

func (ts *Tensor) MustNonzeroOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNorm

func (ts *Tensor) MustNorm(del bool) (retVal *Tensor)

func (*Tensor) MustNorm1

func (ts *Tensor) MustNorm1(p *Scalar, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustNorm2

func (ts *Tensor) MustNorm2(p *Scalar, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustNorm3

func (ts *Tensor) MustNorm3(p *Scalar, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustNormOut

func (ts *Tensor) MustNormOut(out *Tensor, p *Scalar, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustNormOut1

func (ts *Tensor) MustNormOut1(out *Tensor, p *Scalar, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustNormal_

func (ts *Tensor) MustNormal_(mean float64, std float64)

func (*Tensor) MustNotEqual added in v0.3.0

func (ts *Tensor) MustNotEqual(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustNotEqual1 added in v0.3.0

func (ts *Tensor) MustNotEqual1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNotEqual1_ added in v0.3.0

func (ts *Tensor) MustNotEqual1_(other *Tensor)

func (*Tensor) MustNotEqualOut added in v0.3.0

func (ts *Tensor) MustNotEqualOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustNotEqualOut1 added in v0.3.0

func (ts *Tensor) MustNotEqualOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustNotEqual_ added in v0.3.0

func (ts *Tensor) MustNotEqual_(other *Scalar)

func (*Tensor) MustNuclearNorm

func (ts *Tensor) MustNuclearNorm(keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustNuclearNorm1

func (ts *Tensor) MustNuclearNorm1(dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustNuclearNormOut

func (ts *Tensor) MustNuclearNormOut(out *Tensor, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustNuclearNormOut1

func (ts *Tensor) MustNuclearNormOut1(out *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustNumpyT

func (ts *Tensor) MustNumpyT(del bool) (retVal *Tensor)

func (*Tensor) MustOneHot

func (ts *Tensor) MustOneHot(numClasses int64, del bool) (retVal *Tensor)

func (*Tensor) MustOnesLike

func (ts *Tensor) MustOnesLike(del bool) (retVal *Tensor)

func (*Tensor) MustOrgqr

func (ts *Tensor) MustOrgqr(input2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustOrgqrOut

func (ts *Tensor) MustOrgqrOut(out *Tensor, input2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustOrmqr

func (ts *Tensor) MustOrmqr(input2 *Tensor, input3 *Tensor, left bool, transpose bool, del bool) (retVal *Tensor)

func (*Tensor) MustOrmqrOut

func (ts *Tensor) MustOrmqrOut(out *Tensor, input2 *Tensor, input3 *Tensor, left bool, transpose bool, del bool) (retVal *Tensor)

func (*Tensor) MustOuter added in v0.3.0

func (ts *Tensor) MustOuter(vec2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustOuterOut added in v0.3.0

func (ts *Tensor) MustOuterOut(out *Tensor, vec2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustPdist

func (ts *Tensor) MustPdist(p float64, del bool) (retVal *Tensor)

func (*Tensor) MustPermute

func (ts *Tensor) MustPermute(dims []int64, del bool) (retVal *Tensor)

func (*Tensor) MustPinMemory

func (ts *Tensor) MustPinMemory(del bool) (retVal *Tensor)

func (*Tensor) MustPinverse

func (ts *Tensor) MustPinverse(rcond float64, del bool) (retVal *Tensor)

func (*Tensor) MustPixelShuffle

func (ts *Tensor) MustPixelShuffle(upscaleFactor int64, del bool) (retVal *Tensor)

func (*Tensor) MustPoisson

func (ts *Tensor) MustPoisson(del bool) (retVal *Tensor)

func (*Tensor) MustPolygamma

func (ts *Tensor) MustPolygamma(n int64, del bool) (retVal *Tensor)

func (*Tensor) MustPolygammaOut

func (ts *Tensor) MustPolygammaOut(out *Tensor, n int64, del bool) (retVal *Tensor)

func (*Tensor) MustPolygamma_

func (ts *Tensor) MustPolygamma_(n int64)

func (*Tensor) MustPow

func (ts *Tensor) MustPow(exponent *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustPow1

func (ts *Tensor) MustPow1(exponent *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustPow1_

func (ts *Tensor) MustPow1_(exponent *Tensor)

func (*Tensor) MustPowOut

func (ts *Tensor) MustPowOut(out *Tensor, exponent *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustPowOut1

func (ts *Tensor) MustPowOut1(out *Tensor, exponent *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustPow_

func (ts *Tensor) MustPow_(exponent *Scalar)

func (*Tensor) MustPrelu

func (ts *Tensor) MustPrelu(weight *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustProd

func (ts *Tensor) MustProd(dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustProd1

func (ts *Tensor) MustProd1(dim int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustProdOut

func (ts *Tensor) MustProdOut(out *Tensor, dim int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustPut_

func (ts *Tensor) MustPut_(index *Tensor, source *Tensor, accumulate bool)

func (*Tensor) MustQPerChannelScales

func (ts *Tensor) MustQPerChannelScales(del bool) (retVal *Tensor)

func (*Tensor) MustQPerChannelZeroPoints

func (ts *Tensor) MustQPerChannelZeroPoints(del bool) (retVal *Tensor)

func (*Tensor) MustQuantile added in v0.3.0

func (ts *Tensor) MustQuantile(q float64, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustQuantile1 added in v0.3.0

func (ts *Tensor) MustQuantile1(q *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustQuantileOut added in v0.3.0

func (ts *Tensor) MustQuantileOut(out *Tensor, q float64, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustQuantileOut1 added in v0.3.0

func (ts *Tensor) MustQuantileOut1(out *Tensor, q *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustQuantizePerChannel

func (ts *Tensor) MustQuantizePerChannel(scales *Tensor, zeroPoints *Tensor, axis int64, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustQuantizePerTensor

func (ts *Tensor) MustQuantizePerTensor(scale float64, zeroPoint int64, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustQuantizedMaxPool1d added in v0.3.0

func (ts *Tensor) MustQuantizedMaxPool1d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor)

func (*Tensor) MustQuantizedMaxPool2d

func (ts *Tensor) MustQuantizedMaxPool2d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor)

func (*Tensor) MustRad2deg added in v0.3.0

func (ts *Tensor) MustRad2deg(del bool) (retVal *Tensor)

func (*Tensor) MustRad2degOut added in v0.3.0

func (ts *Tensor) MustRad2degOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustRad2deg_ added in v0.3.0

func (ts *Tensor) MustRad2deg_()

func (*Tensor) MustRandLike

func (ts *Tensor) MustRandLike(del bool) (retVal *Tensor)

func (*Tensor) MustRandintLike

func (ts *Tensor) MustRandintLike(high int64, del bool) (retVal *Tensor)

func (*Tensor) MustRandintLike1

func (ts *Tensor) MustRandintLike1(low int64, high int64, del bool) (retVal *Tensor)

func (*Tensor) MustRandnLike

func (ts *Tensor) MustRandnLike(del bool) (retVal *Tensor)

func (*Tensor) MustRandom1_

func (ts *Tensor) MustRandom1_(to int64)

func (*Tensor) MustRandom2

func (ts *Tensor) MustRandom2(from int64, to []int64)

func (*Tensor) MustRandom_

func (ts *Tensor) MustRandom_()

func (*Tensor) MustReal

func (ts *Tensor) MustReal(del bool) (retVal *Tensor)

func (*Tensor) MustReciprocal

func (ts *Tensor) MustReciprocal(del bool) (retVal *Tensor)

func (*Tensor) MustReciprocalOut

func (ts *Tensor) MustReciprocalOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustReciprocal_

func (ts *Tensor) MustReciprocal_()

func (*Tensor) MustReflectionPad1d

func (ts *Tensor) MustReflectionPad1d(padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReflectionPad1dBackward

func (ts *Tensor) MustReflectionPad1dBackward(gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReflectionPad1dBackwardOut

func (ts *Tensor) MustReflectionPad1dBackwardOut(gradInput *Tensor, gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReflectionPad1dOut

func (ts *Tensor) MustReflectionPad1dOut(out *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReflectionPad2d

func (ts *Tensor) MustReflectionPad2d(padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReflectionPad2dBackward

func (ts *Tensor) MustReflectionPad2dBackward(gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReflectionPad2dBackwardOut

func (ts *Tensor) MustReflectionPad2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReflectionPad2dOut

func (ts *Tensor) MustReflectionPad2dOut(out *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustRelu

func (ts *Tensor) MustRelu(del bool) (retVal *Tensor)

func (*Tensor) MustRelu_

func (ts *Tensor) MustRelu_()

func (*Tensor) MustRemainder

func (ts *Tensor) MustRemainder(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustRemainder1

func (ts *Tensor) MustRemainder1(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustRemainder1_

func (ts *Tensor) MustRemainder1_(other *Tensor)

func (*Tensor) MustRemainderOut

func (ts *Tensor) MustRemainderOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustRemainderOut1

func (ts *Tensor) MustRemainderOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustRemainder_

func (ts *Tensor) MustRemainder_(other *Scalar)

func (*Tensor) MustRenorm

func (ts *Tensor) MustRenorm(p *Scalar, dim int64, maxnorm *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustRenormOut

func (ts *Tensor) MustRenormOut(out *Tensor, p *Scalar, dim int64, maxnorm *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustRenorm_

func (ts *Tensor) MustRenorm_(p *Scalar, dim int64, maxnorm *Scalar)

func (*Tensor) MustRepeat

func (ts *Tensor) MustRepeat(repeats []int64, del bool) (retVal *Tensor)

func (*Tensor) MustRepeatInterleave1

func (ts *Tensor) MustRepeatInterleave1(repeats *Tensor, dim []int64, del bool) (retVal *Tensor)

func (*Tensor) MustRepeatInterleave2

func (ts *Tensor) MustRepeatInterleave2(repeats int64, dim []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReplicationPad1d

func (ts *Tensor) MustReplicationPad1d(padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReplicationPad1dBackward

func (ts *Tensor) MustReplicationPad1dBackward(gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReplicationPad1dBackwardOut

func (ts *Tensor) MustReplicationPad1dBackwardOut(gradInput *Tensor, gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReplicationPad1dOut

func (ts *Tensor) MustReplicationPad1dOut(out *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReplicationPad2d

func (ts *Tensor) MustReplicationPad2d(padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReplicationPad2dBackward

func (ts *Tensor) MustReplicationPad2dBackward(gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReplicationPad2dBackwardOut

func (ts *Tensor) MustReplicationPad2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReplicationPad2dOut

func (ts *Tensor) MustReplicationPad2dOut(out *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReplicationPad3d

func (ts *Tensor) MustReplicationPad3d(padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReplicationPad3dBackward

func (ts *Tensor) MustReplicationPad3dBackward(gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReplicationPad3dBackwardOut

func (ts *Tensor) MustReplicationPad3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReplicationPad3dOut

func (ts *Tensor) MustReplicationPad3dOut(out *Tensor, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustRequiresGrad

func (ts *Tensor) MustRequiresGrad() bool

func (*Tensor) MustRequiresGrad_

func (ts *Tensor) MustRequiresGrad_(requiresGrad bool)

func (*Tensor) MustReshape

func (ts *Tensor) MustReshape(shape []int64, del bool) (retVal *Tensor)

func (*Tensor) MustReshapeAs

func (ts *Tensor) MustReshapeAs(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustResizeAs_

func (ts *Tensor) MustResizeAs_(theTemplate *Tensor)

func (*Tensor) MustResize_

func (ts *Tensor) MustResize_(size []int64)

func (*Tensor) MustRfft

func (ts *Tensor) MustRfft(signalNdim int64, normalized bool, onesided bool, del bool) (retVal *Tensor)

func (*Tensor) MustRoll

func (ts *Tensor) MustRoll(shifts []int64, dims []int64, del bool) (retVal *Tensor)

func (*Tensor) MustRot90

func (ts *Tensor) MustRot90(k int64, dims []int64, del bool) (retVal *Tensor)

func (*Tensor) MustRound

func (ts *Tensor) MustRound(del bool) (retVal *Tensor)

func (*Tensor) MustRoundOut

func (ts *Tensor) MustRoundOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustRound_

func (ts *Tensor) MustRound_()

func (*Tensor) MustRrelu

func (ts *Tensor) MustRrelu(training bool, del bool) (retVal *Tensor)

func (*Tensor) MustRreluWithNoise

func (ts *Tensor) MustRreluWithNoise(noise *Tensor, training bool, del bool) (retVal *Tensor)

func (*Tensor) MustRreluWithNoiseBackward

func (ts *Tensor) MustRreluWithNoiseBackward(gradOutput *Tensor, noise *Tensor, lower *Scalar, upper *Scalar, training bool, selfIsResult bool, del bool) (retVal *Tensor)

func (*Tensor) MustRreluWithNoiseOut

func (ts *Tensor) MustRreluWithNoiseOut(out *Tensor, noise *Tensor, training bool, del bool) (retVal *Tensor)

func (*Tensor) MustRreluWithNoise_

func (ts *Tensor) MustRreluWithNoise_(noise *Tensor, training bool)

func (*Tensor) MustRrelu_

func (ts *Tensor) MustRrelu_(training bool)

func (*Tensor) MustRsqrt

func (ts *Tensor) MustRsqrt(del bool) (retVal *Tensor)

func (*Tensor) MustRsqrtOut

func (ts *Tensor) MustRsqrtOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustRsqrt_

func (ts *Tensor) MustRsqrt_()

func (*Tensor) MustRsub

func (ts *Tensor) MustRsub(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustRsub1

func (ts *Tensor) MustRsub1(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustSave

func (ts *Tensor) MustSave(path string)

MustSave saves a tensor to a file. It will panic if error

func (*Tensor) MustScatter

func (ts *Tensor) MustScatter(dim int64, index *Tensor, src *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustScatter1

func (ts *Tensor) MustScatter1(dim int64, index *Tensor, value *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustScatter1_

func (ts *Tensor) MustScatter1_(dim int64, index *Tensor, value *Scalar)

func (*Tensor) MustScatter2 added in v0.3.0

func (ts *Tensor) MustScatter2(dim int64, index *Tensor, src *Tensor, reduce string)

func (*Tensor) MustScatter3 added in v0.3.0

func (ts *Tensor) MustScatter3(dim int64, index *Tensor, value *Scalar, reduce string)

func (*Tensor) MustScatterAdd

func (ts *Tensor) MustScatterAdd(dim int64, index *Tensor, src *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustScatterAdd_

func (ts *Tensor) MustScatterAdd_(dim int64, index *Tensor, src *Tensor)

func (*Tensor) MustScatter_

func (ts *Tensor) MustScatter_(dim int64, index *Tensor, src *Tensor)

func (*Tensor) MustSearchsorted added in v0.3.0

func (ts *Tensor) MustSearchsorted(sortedSequence *Tensor, outInt32 bool, right bool, del bool) (retVal *Tensor)

func (*Tensor) MustSearchsortedOut added in v0.3.0

func (ts *Tensor) MustSearchsortedOut(out *Tensor, sortedSequence *Tensor, outInt32 bool, right bool, del bool) (retVal *Tensor)

func (*Tensor) MustSelect

func (ts *Tensor) MustSelect(dim int64, index int64, del bool) (retVal *Tensor)

func (*Tensor) MustSelu

func (ts *Tensor) MustSelu(del bool) (retVal *Tensor)

func (*Tensor) MustSelu_

func (ts *Tensor) MustSelu_()

func (*Tensor) MustSet1_

func (ts *Tensor) MustSet1_(source *Tensor)

func (*Tensor) MustSetRequiresGrad

func (ts *Tensor) MustSetRequiresGrad(r bool, del bool) (retVal *Tensor)

func (*Tensor) MustSet_

func (ts *Tensor) MustSet_()

func (*Tensor) MustSgn added in v0.3.0

func (ts *Tensor) MustSgn(del bool) (retVal *Tensor)

func (*Tensor) MustSgnOut added in v0.3.0

func (ts *Tensor) MustSgnOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSgn_ added in v0.3.0

func (ts *Tensor) MustSgn_()

func (*Tensor) MustShallowClone

func (ts *Tensor) MustShallowClone() *Tensor

MustShallowClone returns a new tensor that share storage with the input tensor. It will panic if error occurred

func (*Tensor) MustSigmoid

func (ts *Tensor) MustSigmoid(del bool) (retVal *Tensor)

func (*Tensor) MustSigmoidOut

func (ts *Tensor) MustSigmoidOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSigmoid_

func (ts *Tensor) MustSigmoid_()

func (*Tensor) MustSign

func (ts *Tensor) MustSign(del bool) (retVal *Tensor)

func (*Tensor) MustSignOut

func (ts *Tensor) MustSignOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSign_

func (ts *Tensor) MustSign_()

func (*Tensor) MustSignbit added in v0.3.0

func (ts *Tensor) MustSignbit(del bool) (retVal *Tensor)

func (*Tensor) MustSignbitOut added in v0.3.0

func (ts *Tensor) MustSignbitOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSilu added in v0.3.0

func (ts *Tensor) MustSilu(del bool) (retVal *Tensor)

func (*Tensor) MustSiluBackward added in v0.3.0

func (ts *Tensor) MustSiluBackward(gradOutput *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSiluOut added in v0.3.0

func (ts *Tensor) MustSiluOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSilu_ added in v0.3.0

func (ts *Tensor) MustSilu_()

func (*Tensor) MustSin

func (ts *Tensor) MustSin(del bool) (retVal *Tensor)

func (*Tensor) MustSinOut

func (ts *Tensor) MustSinOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSin_

func (ts *Tensor) MustSin_()

func (*Tensor) MustSinh

func (ts *Tensor) MustSinh(del bool) (retVal *Tensor)

func (*Tensor) MustSinhOut

func (ts *Tensor) MustSinhOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSinh_

func (ts *Tensor) MustSinh_()

func (*Tensor) MustSize

func (ts *Tensor) MustSize() []int64

func (*Tensor) MustSlice

func (ts *Tensor) MustSlice(dim int64, start int64, end int64, step int64, del bool) (retVal *Tensor)

func (*Tensor) MustSlowConv3d

func (ts *Tensor) MustSlowConv3d(weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustSlowConv3dOut

func (ts *Tensor) MustSlowConv3dOut(out *Tensor, weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, del bool) (retVal *Tensor)

func (*Tensor) MustSlowConvDilated2d

func (ts *Tensor) MustSlowConvDilated2d(weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, dilation []int64, del bool) (retVal *Tensor)

func (*Tensor) MustSlowConvDilated3d

func (ts *Tensor) MustSlowConvDilated3d(weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, dilation []int64, del bool) (retVal *Tensor)

func (*Tensor) MustSlowConvTranspose2d

func (ts *Tensor) MustSlowConvTranspose2d(weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, dilation []int64, del bool) (retVal *Tensor)

func (*Tensor) MustSlowConvTranspose2dOut

func (ts *Tensor) MustSlowConvTranspose2dOut(out *Tensor, weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, dilation []int64, del bool) (retVal *Tensor)

func (*Tensor) MustSlowConvTranspose3d

func (ts *Tensor) MustSlowConvTranspose3d(weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, dilation []int64, del bool) (retVal *Tensor)

func (*Tensor) MustSlowConvTranspose3dOut

func (ts *Tensor) MustSlowConvTranspose3dOut(out *Tensor, weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, dilation []int64, del bool) (retVal *Tensor)

func (*Tensor) MustSmm

func (ts *Tensor) MustSmm(mat2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSmoothL1Loss

func (ts *Tensor) MustSmoothL1Loss(target *Tensor, reduction int64, beta float64, del bool) (retVal *Tensor)

func (*Tensor) MustSmoothL1LossBackward

func (ts *Tensor) MustSmoothL1LossBackward(gradOutput *Tensor, target *Tensor, reduction int64, beta float64, del bool) (retVal *Tensor)

func (*Tensor) MustSmoothL1LossBackwardOut

func (ts *Tensor) MustSmoothL1LossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, reduction int64, beta float64, del bool) (retVal *Tensor)

func (*Tensor) MustSmoothL1LossOut

func (ts *Tensor) MustSmoothL1LossOut(out *Tensor, target *Tensor, reduction int64, beta float64, del bool) (retVal *Tensor)

func (*Tensor) MustSoftMarginLoss

func (ts *Tensor) MustSoftMarginLoss(target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustSoftMarginLossBackward

func (ts *Tensor) MustSoftMarginLossBackward(gradOutput *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustSoftMarginLossBackwardOut

func (ts *Tensor) MustSoftMarginLossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustSoftMarginLossOut

func (ts *Tensor) MustSoftMarginLossOut(out *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor)

func (*Tensor) MustSoftmax

func (ts *Tensor) MustSoftmax(dim int64, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustSoftplus

func (ts *Tensor) MustSoftplus(del bool) (retVal *Tensor)

func (*Tensor) MustSoftplusBackward

func (ts *Tensor) MustSoftplusBackward(gradOutput *Tensor, beta *Scalar, threshold *Scalar, output *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSoftplusBackwardOut

func (ts *Tensor) MustSoftplusBackwardOut(gradInput *Tensor, gradOutput *Tensor, beta *Scalar, threshold *Scalar, output *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSoftplusOut

func (ts *Tensor) MustSoftplusOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSoftshrink

func (ts *Tensor) MustSoftshrink(del bool) (retVal *Tensor)

func (*Tensor) MustSoftshrinkBackward

func (ts *Tensor) MustSoftshrinkBackward(gradOutput *Tensor, lambd *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustSoftshrinkBackwardOut

func (ts *Tensor) MustSoftshrinkBackwardOut(gradInput *Tensor, gradOutput *Tensor, lambd *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustSoftshrinkOut

func (ts *Tensor) MustSoftshrinkOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSparseMask

func (ts *Tensor) MustSparseMask(mask *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSparseResizeAndClear_

func (ts *Tensor) MustSparseResizeAndClear_(size []int64, sparseDim int64, denseDim int64)

func (*Tensor) MustSparseResize_

func (ts *Tensor) MustSparseResize_(size []int64, sparseDim int64, denseDim int64)

func (*Tensor) MustSplit

func (ts *Tensor) MustSplit(splitSize, dim int64, del bool) (retVal []Tensor)

func (*Tensor) MustSplitWithSizes

func (ts *Tensor) MustSplitWithSizes(splitSizes []int64, dim int64, del bool) (retVal []Tensor)

func (*Tensor) MustSqrt

func (ts *Tensor) MustSqrt(del bool) (retVal *Tensor)

func (*Tensor) MustSqrtOut

func (ts *Tensor) MustSqrtOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSqrt_

func (ts *Tensor) MustSqrt_()

func (*Tensor) MustSquare

func (ts *Tensor) MustSquare(del bool) (retVal *Tensor)

func (*Tensor) MustSquare_

func (ts *Tensor) MustSquare_()

func (*Tensor) MustSqueeze

func (ts *Tensor) MustSqueeze(del bool) (retVal *Tensor)

func (*Tensor) MustSqueeze1

func (ts *Tensor) MustSqueeze1(dim int64, del bool) (retVal *Tensor)

func (*Tensor) MustSqueeze1_

func (ts *Tensor) MustSqueeze1_(dim int64)

func (*Tensor) MustSqueeze_

func (ts *Tensor) MustSqueeze_()

func (*Tensor) MustSspaddmm

func (ts *Tensor) MustSspaddmm(mat1 *Tensor, mat2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSspaddmmOut

func (ts *Tensor) MustSspaddmmOut(out *Tensor, mat1 *Tensor, mat2 *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustStd

func (ts *Tensor) MustStd(unbiased bool, del bool) (retVal *Tensor)

func (*Tensor) MustStd1

func (ts *Tensor) MustStd1(dim []int64, unbiased bool, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustStdOut

func (ts *Tensor) MustStdOut(out *Tensor, dim []int64, unbiased bool, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustStft

func (ts *Tensor) MustStft(nFft int64, hopLength []int64, winLength []int64, window *Tensor, normalized bool, onesided bool, returnComplex bool, del bool) (retVal *Tensor)

func (*Tensor) MustSub

func (ts *Tensor) MustSub(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSub1

func (ts *Tensor) MustSub1(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustSub1_

func (ts *Tensor) MustSub1_(other *Scalar)

func (*Tensor) MustSubOut

func (ts *Tensor) MustSubOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSub_

func (ts *Tensor) MustSub_(other *Tensor)

func (*Tensor) MustSubtract added in v0.3.0

func (ts *Tensor) MustSubtract(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSubtract1 added in v0.3.0

func (ts *Tensor) MustSubtract1(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustSubtract1_ added in v0.3.0

func (ts *Tensor) MustSubtract1_(other *Scalar)

func (*Tensor) MustSubtractOut added in v0.3.0

func (ts *Tensor) MustSubtractOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustSubtract_ added in v0.3.0

func (ts *Tensor) MustSubtract_(other *Tensor)

func (*Tensor) MustSum

func (ts *Tensor) MustSum(dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustSum1

func (ts *Tensor) MustSum1(dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustSumOut

func (ts *Tensor) MustSumOut(out *Tensor, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustSumToSize

func (ts *Tensor) MustSumToSize(size []int64, del bool) (retVal *Tensor)

func (*Tensor) MustT

func (ts *Tensor) MustT(del bool) (retVal *Tensor)

func (*Tensor) MustT_

func (ts *Tensor) MustT_()

func (*Tensor) MustTake

func (ts *Tensor) MustTake(index *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustTakeOut

func (ts *Tensor) MustTakeOut(out *Tensor, index *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustTan

func (ts *Tensor) MustTan(del bool) (retVal *Tensor)

func (*Tensor) MustTanOut

func (ts *Tensor) MustTanOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustTan_

func (ts *Tensor) MustTan_()

func (*Tensor) MustTanh

func (ts *Tensor) MustTanh(del bool) (retVal *Tensor)

func (*Tensor) MustTanhOut

func (ts *Tensor) MustTanhOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustTanh_

func (ts *Tensor) MustTanh_()

func (*Tensor) MustTensordot

func (ts *Tensor) MustTensordot(other *Tensor, dimsSelf []int64, dimsOther []int64, del bool) (retVal *Tensor)

func (*Tensor) MustThreshold

func (ts *Tensor) MustThreshold(threshold *Scalar, value *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustThresholdBackward

func (ts *Tensor) MustThresholdBackward(gradOutput *Tensor, threshold *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustThresholdOut

func (ts *Tensor) MustThresholdOut(out *Tensor, threshold *Scalar, value *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustThreshold_

func (ts *Tensor) MustThreshold_(threshold *Scalar, value *Scalar)

func (*Tensor) MustTo

func (ts *Tensor) MustTo(device gotch.Device, del bool) (retVal *Tensor)

func (*Tensor) MustTo1

func (ts *Tensor) MustTo1(optionsKind gotch.DType, optionsDevice gotch.Device, nonBlocking bool, copy bool, del bool) (retVal *Tensor)

func (*Tensor) MustTo2

func (ts *Tensor) MustTo2(dtype gotch.DType, nonBlocking bool, copy bool, del bool) (retVal *Tensor)

func (*Tensor) MustTo3

func (ts *Tensor) MustTo3(other *Tensor, nonBlocking bool, copy bool, del bool) (retVal *Tensor)

func (*Tensor) MustTo4

func (ts *Tensor) MustTo4(device gotch.Device, dtype gotch.DType, nonBlocking bool, copy bool, del bool) (retVal *Tensor)

func (*Tensor) MustToDense

func (ts *Tensor) MustToDense(del bool) (retVal *Tensor)

func (*Tensor) MustToMkldnn

func (ts *Tensor) MustToMkldnn(del bool) (retVal *Tensor)

func (*Tensor) MustToSparse

func (ts *Tensor) MustToSparse(del bool) (retVal *Tensor)

func (*Tensor) MustToSparse1

func (ts *Tensor) MustToSparse1(sparseDim int64, del bool) (retVal *Tensor)

func (*Tensor) MustToString

func (ts *Tensor) MustToString(lw int64) string

MustToString returns a string representation for the tensor. It will be panic if error. lw : line width (size)

func (*Tensor) MustTopK

func (ts *Tensor) MustTopK(k int64, dim int64, largest bool, sorted bool) (ts1, ts2 *Tensor)

func (*Tensor) MustTotype

func (ts *Tensor) MustTotype(scalarType gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) MustTrace

func (ts *Tensor) MustTrace(del bool) (retVal *Tensor)

func (*Tensor) MustTranspose

func (ts *Tensor) MustTranspose(dim0 int64, dim1 int64, del bool) (retVal *Tensor)

func (*Tensor) MustTranspose_

func (ts *Tensor) MustTranspose_(dim0 int64, dim1 int64)

func (*Tensor) MustTril

func (ts *Tensor) MustTril(diagonal int64, del bool) (retVal *Tensor)

func (*Tensor) MustTrilOut

func (ts *Tensor) MustTrilOut(out *Tensor, diagonal int64, del bool) (retVal *Tensor)

func (*Tensor) MustTril_

func (ts *Tensor) MustTril_(diagonal int64)

func (*Tensor) MustTriu

func (ts *Tensor) MustTriu(diagonal int64, del bool) (retVal *Tensor)

func (*Tensor) MustTriuOut

func (ts *Tensor) MustTriuOut(out *Tensor, diagonal int64, del bool) (retVal *Tensor)

func (*Tensor) MustTriu_

func (ts *Tensor) MustTriu_(diagonal int64)

func (*Tensor) MustTrueDivide

func (ts *Tensor) MustTrueDivide(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustTrueDivide1

func (ts *Tensor) MustTrueDivide1(other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustTrueDivide1_

func (ts *Tensor) MustTrueDivide1_(other *Scalar)

func (*Tensor) MustTrueDivideOut

func (ts *Tensor) MustTrueDivideOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustTrueDivide_

func (ts *Tensor) MustTrueDivide_(other *Tensor)

func (*Tensor) MustTrunc

func (ts *Tensor) MustTrunc(del bool) (retVal *Tensor)

func (*Tensor) MustTruncOut

func (ts *Tensor) MustTruncOut(out *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustTrunc_

func (ts *Tensor) MustTrunc_()

func (*Tensor) MustTypeAs

func (ts *Tensor) MustTypeAs(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustUnbind

func (ts *Tensor) MustUnbind(dim int64, del bool) (retVal []Tensor)

func (*Tensor) MustUnflatten added in v0.3.0

func (ts *Tensor) MustUnflatten(dim int64, sizes []int64, del bool) (retVal *Tensor)

func (*Tensor) MustUnfold

func (ts *Tensor) MustUnfold(dimension int64, size int64, step int64, del bool) (retVal *Tensor)

func (*Tensor) MustUniform_

func (ts *Tensor) MustUniform_(from float64, to float64)

func (*Tensor) MustUnsqueeze

func (ts *Tensor) MustUnsqueeze(dim int64, del bool) (retVal *Tensor)

func (*Tensor) MustUnsqueeze_

func (ts *Tensor) MustUnsqueeze_(dim int64)

func (*Tensor) MustUpsampleBicubic2d

func (ts *Tensor) MustUpsampleBicubic2d(outputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleBicubic2dOut

func (ts *Tensor) MustUpsampleBicubic2dOut(out *Tensor, outputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleBilinear2d

func (ts *Tensor) MustUpsampleBilinear2d(outputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleBilinear2dOut

func (ts *Tensor) MustUpsampleBilinear2dOut(out *Tensor, outputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleLinear1d

func (ts *Tensor) MustUpsampleLinear1d(outputSize []int64, alignCorners bool, scales []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleLinear1dOut

func (ts *Tensor) MustUpsampleLinear1dOut(out *Tensor, outputSize []int64, alignCorners bool, scales []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleNearest1d

func (ts *Tensor) MustUpsampleNearest1d(outputSize []int64, scales []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleNearest1dOut

func (ts *Tensor) MustUpsampleNearest1dOut(out *Tensor, outputSize []int64, scales []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleNearest2d

func (ts *Tensor) MustUpsampleNearest2d(outputSize []int64, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleNearest2dOut

func (ts *Tensor) MustUpsampleNearest2dOut(out *Tensor, outputSize []int64, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleNearest3d

func (ts *Tensor) MustUpsampleNearest3d(outputSize []int64, scalesD []float64, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleNearest3dOut

func (ts *Tensor) MustUpsampleNearest3dOut(out *Tensor, outputSize []int64, scalesD []float64, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleTrilinear3d

func (ts *Tensor) MustUpsampleTrilinear3d(outputSize []int64, alignCorners bool, scalesD []float64, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor)

func (*Tensor) MustUpsampleTrilinear3dOut

func (ts *Tensor) MustUpsampleTrilinear3dOut(out *Tensor, outputSize []int64, alignCorners bool, scalesD []float64, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor)

func (*Tensor) MustValues

func (ts *Tensor) MustValues(del bool) (retVal *Tensor)

func (*Tensor) MustVar

func (ts *Tensor) MustVar(unbiased bool, del bool) (retVal *Tensor)

func (*Tensor) MustVar1

func (ts *Tensor) MustVar1(dim []int64, unbiased bool, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustVarOut

func (ts *Tensor) MustVarOut(out *Tensor, dim []int64, unbiased bool, keepdim bool, del bool) (retVal *Tensor)

func (*Tensor) MustVdot added in v0.3.0

func (ts *Tensor) MustVdot(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustVdotOut added in v0.3.0

func (ts *Tensor) MustVdotOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustView

func (ts *Tensor) MustView(size []int64, del bool) (retVal *Tensor)

func (*Tensor) MustViewAs

func (ts *Tensor) MustViewAs(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustViewAsComplex added in v0.3.0

func (ts *Tensor) MustViewAsComplex(del bool) (retVal *Tensor)

func (*Tensor) MustViewAsReal added in v0.3.0

func (ts *Tensor) MustViewAsReal(del bool) (retVal *Tensor)

func (*Tensor) MustWhere1

func (ts *Tensor) MustWhere1(condition *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) MustWhere3 added in v0.3.0

func (ts *Tensor) MustWhere3(condition *Tensor, other *Scalar, del bool) (retVal *Tensor)

func (*Tensor) MustZeroPad2d

func (ts *Tensor) MustZeroPad2d(left, right, top, bottom int64, del bool) *Tensor

func (*Tensor) MustZero_

func (ts *Tensor) MustZero_()

func (*Tensor) MustZerosLike

func (ts *Tensor) MustZerosLike(del bool) (retVal *Tensor)

func (*Tensor) Must_AdaptiveAvgPool2d

func (ts *Tensor) Must_AdaptiveAvgPool2d(outputSize []int64, del bool) (retVal *Tensor)

func (*Tensor) Must_AdaptiveAvgPool2dBackward

func (ts *Tensor) Must_AdaptiveAvgPool2dBackward(gradOutput *Tensor, del bool) (retVal *Tensor)

func (*Tensor) Must_AddBatchDim added in v0.3.0

func (ts *Tensor) Must_AddBatchDim(batchDim int64, level int64, del bool) (retVal *Tensor)

func (*Tensor) Must_AddRelu added in v0.3.0

func (ts *Tensor) Must_AddRelu(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) Must_AddReluOut added in v0.3.0

func (ts *Tensor) Must_AddReluOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) Must_AddRelu_ added in v0.3.0

func (ts *Tensor) Must_AddRelu_(other *Tensor)

func (*Tensor) Must_AddmvImpl_ added in v0.3.0

func (ts *Tensor) Must_AddmvImpl_(self2 *Tensor, mat *Tensor, vec *Tensor)

func (*Tensor) Must_BaddbmmMkl_

func (ts *Tensor) Must_BaddbmmMkl_(batch1 *Tensor, batch2 *Tensor)

func (*Tensor) Must_Bmm added in v0.3.0

func (ts *Tensor) Must_Bmm(mat2 *Tensor, deterministic bool, del bool) (retVal *Tensor)

func (*Tensor) Must_BmmOut added in v0.3.0

func (ts *Tensor) Must_BmmOut(out *Tensor, mat2 *Tensor, deterministic bool, del bool) (retVal *Tensor)

func (*Tensor) Must_CastByte

func (ts *Tensor) Must_CastByte(nonBlocking bool, del bool) (retVal *Tensor)

func (*Tensor) Must_CastChar

func (ts *Tensor) Must_CastChar(nonBlocking bool, del bool) (retVal *Tensor)

func (*Tensor) Must_CastDouble

func (ts *Tensor) Must_CastDouble(nonBlocking bool, del bool) (retVal *Tensor)

func (*Tensor) Must_CastFloat

func (ts *Tensor) Must_CastFloat(nonBlocking bool, del bool) (retVal *Tensor)

func (*Tensor) Must_CastHalf

func (ts *Tensor) Must_CastHalf(nonBlocking bool, del bool) (retVal *Tensor)

func (*Tensor) Must_CastInt

func (ts *Tensor) Must_CastInt(nonBlocking bool, del bool) (retVal *Tensor)

func (*Tensor) Must_CastLong

func (ts *Tensor) Must_CastLong(nonBlocking bool, del bool) (retVal *Tensor)

func (*Tensor) Must_CastShort

func (ts *Tensor) Must_CastShort(nonBlocking bool, del bool) (retVal *Tensor)

func (*Tensor) Must_CholeskyHelper

func (ts *Tensor) Must_CholeskyHelper(upper bool, del bool) (retVal *Tensor)

func (*Tensor) Must_CholeskySolveHelper

func (ts *Tensor) Must_CholeskySolveHelper(a *Tensor, upper bool, del bool) (retVal *Tensor)

func (*Tensor) Must_Coalesced_

func (ts *Tensor) Must_Coalesced_(coalesced bool)

func (*Tensor) Must_Conj added in v0.3.0

func (ts *Tensor) Must_Conj(del bool) (retVal *Tensor)

func (*Tensor) Must_CopyFrom

func (ts *Tensor) Must_CopyFrom(dst *Tensor, nonBlocking bool, del bool) (retVal *Tensor)

func (*Tensor) Must_Cumprod

func (ts *Tensor) Must_Cumprod(dim int64, del bool) (retVal *Tensor)

func (*Tensor) Must_CumprodOut

func (ts *Tensor) Must_CumprodOut(out *Tensor, dim int64, del bool) (retVal *Tensor)

func (*Tensor) Must_Cumsum

func (ts *Tensor) Must_Cumsum(dim int64, del bool) (retVal *Tensor)

func (*Tensor) Must_CumsumOut

func (ts *Tensor) Must_CumsumOut(out *Tensor, dim int64, del bool) (retVal *Tensor)

func (*Tensor) Must_FakeQuantizeLearnablePerChannelAffine added in v0.3.0

func (ts *Tensor) Must_FakeQuantizeLearnablePerChannelAffine(scale *Tensor, zeroPoint *Tensor, axis int64, quantMin int64, quantMax int64, del bool) (retVal *Tensor)

func (*Tensor) Must_FakeQuantizeLearnablePerTensorAffine added in v0.3.0

func (ts *Tensor) Must_FakeQuantizeLearnablePerTensorAffine(scale *Tensor, zeroPoint *Tensor, quantMin int64, quantMax int64, del bool) (retVal *Tensor)

func (*Tensor) Must_FftWithSize

func (ts *Tensor) Must_FftWithSize(signalNdim int64, complexInput bool, complexOutput bool, inverse bool, checkedSignalSizes []int64, normalized bool, onesided bool, outputSizes []int64, del bool) (retVal *Tensor)

func (*Tensor) Must_FftWithSize1 added in v0.3.0

func (ts *Tensor) Must_FftWithSize1(signalNdim int64, complexInput bool, complexOutput bool, inverse bool, checkedSignalSizes []int64, normalization int64, onesided bool, outputSizes []int64, del bool) (retVal *Tensor)

func (*Tensor) Must_GatherSparseBackward

func (ts *Tensor) Must_GatherSparseBackward(dim int64, index *Tensor, grad *Tensor, del bool) (retVal *Tensor)

func (*Tensor) Must_IndexCopy_

func (ts *Tensor) Must_IndexCopy_(dim int64, index *Tensor, source *Tensor)

func (*Tensor) Must_IndexPutImpl_

func (ts *Tensor) Must_IndexPutImpl_(indices []Tensor, values *Tensor, accumulate bool, unsafety bool)

func (*Tensor) Must_Indices

func (ts *Tensor) Must_Indices(del bool) (retVal *Tensor)

func (*Tensor) Must_InverseHelper

func (ts *Tensor) Must_InverseHelper(del bool) (retVal *Tensor)

func (*Tensor) Must_LogSoftmax

func (ts *Tensor) Must_LogSoftmax(dim int64, halfToFloat bool, del bool) (retVal *Tensor)

func (*Tensor) Must_LogSoftmaxBackwardData

func (ts *Tensor) Must_LogSoftmaxBackwardData(gradOutput *Tensor, output *Tensor, dim int64, del bool) (retVal *Tensor)

func (*Tensor) Must_Logcumsumexp added in v0.3.0

func (ts *Tensor) Must_Logcumsumexp(dim int64, del bool) (retVal *Tensor)

func (*Tensor) Must_LogcumsumexpOut added in v0.3.0

func (ts *Tensor) Must_LogcumsumexpOut(out *Tensor, dim int64, del bool) (retVal *Tensor)

func (*Tensor) Must_LuSolveHelper

func (ts *Tensor) Must_LuSolveHelper(lUData *Tensor, lUPivots *Tensor, del bool) (retVal *Tensor)

func (*Tensor) Must_MakePerChannelQuantizedTensor

func (ts *Tensor) Must_MakePerChannelQuantizedTensor(scale *Tensor, zeroPoint *Tensor, axis int64, del bool) (retVal *Tensor)

func (*Tensor) Must_MakePerTensorQuantizedTensor

func (ts *Tensor) Must_MakePerTensorQuantizedTensor(scale float64, zeroPoint int64, del bool) (retVal *Tensor)

func (*Tensor) Must_MaskedScale

func (ts *Tensor) Must_MaskedScale(mask *Tensor, scale float64, del bool) (retVal *Tensor)

func (*Tensor) Must_MkldnnReshape

func (ts *Tensor) Must_MkldnnReshape(shape []int64, del bool) (retVal *Tensor)

func (*Tensor) Must_MkldnnTranspose

func (ts *Tensor) Must_MkldnnTranspose(dim0 int64, dim1 int64, del bool) (retVal *Tensor)

func (*Tensor) Must_MkldnnTranspose_

func (ts *Tensor) Must_MkldnnTranspose_(dim0 int64, dim1 int64)

func (*Tensor) Must_PdistBackward

func (ts *Tensor) Must_PdistBackward(grad *Tensor, p float64, pdist *Tensor, del bool) (retVal *Tensor)

func (*Tensor) Must_RemoveBatchDim added in v0.3.0

func (ts *Tensor) Must_RemoveBatchDim(level int64, batchSize int64, outDim int64, del bool) (retVal *Tensor)

func (*Tensor) Must_ReshapeFromTensor

func (ts *Tensor) Must_ReshapeFromTensor(shape *Tensor, del bool) (retVal *Tensor)

func (*Tensor) Must_SWhere

func (ts *Tensor) Must_SWhere(condition *Tensor, other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) Must_SampleDirichlet

func (ts *Tensor) Must_SampleDirichlet(del bool) (retVal *Tensor)

func (*Tensor) Must_ShapeAsTensor

func (ts *Tensor) Must_ShapeAsTensor(del bool) (retVal *Tensor)

func (*Tensor) Must_SobolEngineFf_

func (ts *Tensor) Must_SobolEngineFf_(n int64, sobolstate *Tensor, dimension int64, numGenerated int64)

func (*Tensor) Must_SobolEngineInitializeState_

func (ts *Tensor) Must_SobolEngineInitializeState_(dimension int64)

func (*Tensor) Must_SobolEngineScramble_

func (ts *Tensor) Must_SobolEngineScramble_(ltm *Tensor, dimension int64)

func (*Tensor) Must_Softmax

func (ts *Tensor) Must_Softmax(dim int64, halfToFloat bool, del bool) (retVal *Tensor)

func (*Tensor) Must_SoftmaxBackwardData

func (ts *Tensor) Must_SoftmaxBackwardData(gradOutput *Tensor, output *Tensor, dim int64, del bool) (retVal *Tensor)

func (*Tensor) Must_SparseAddmm

func (ts *Tensor) Must_SparseAddmm(sparse *Tensor, dense *Tensor, del bool) (retVal *Tensor)

func (*Tensor) Must_SparseLogSoftmax added in v0.3.0

func (ts *Tensor) Must_SparseLogSoftmax(dim int64, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) Must_SparseLogSoftmax1 added in v0.3.0

func (ts *Tensor) Must_SparseLogSoftmax1(dim int64, halfToFloat bool, del bool) (retVal *Tensor)

func (*Tensor) Must_SparseLogSoftmaxBackwardData added in v0.3.0

func (ts *Tensor) Must_SparseLogSoftmaxBackwardData(gradOutput *Tensor, output *Tensor, dim int64, del bool) (retVal *Tensor)

func (*Tensor) Must_SparseSoftmax added in v0.3.0

func (ts *Tensor) Must_SparseSoftmax(dim int64, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) Must_SparseSoftmax1 added in v0.3.0

func (ts *Tensor) Must_SparseSoftmax1(dim int64, halfToFloat bool, del bool) (retVal *Tensor)

func (*Tensor) Must_SparseSoftmaxBackwardData added in v0.3.0

func (ts *Tensor) Must_SparseSoftmaxBackwardData(gradOutput *Tensor, output *Tensor, dim int64, del bool) (retVal *Tensor)

func (*Tensor) Must_SparseSum

func (ts *Tensor) Must_SparseSum(del bool) (retVal *Tensor)

func (*Tensor) Must_SparseSum1

func (ts *Tensor) Must_SparseSum1(dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) Must_SparseSum2

func (ts *Tensor) Must_SparseSum2(dim []int64, del bool) (retVal *Tensor)

func (*Tensor) Must_SparseSum3

func (ts *Tensor) Must_SparseSum3(dim []int64, dtype gotch.DType, del bool) (retVal *Tensor)

func (*Tensor) Must_SparseSumBackward

func (ts *Tensor) Must_SparseSumBackward(grad *Tensor, dim []int64, del bool) (retVal *Tensor)

func (*Tensor) Must_StandardGamma

func (ts *Tensor) Must_StandardGamma(del bool) (retVal *Tensor)

func (*Tensor) Must_StandardGammaGrad

func (ts *Tensor) Must_StandardGammaGrad(output *Tensor, del bool) (retVal *Tensor)

func (*Tensor) Must_Std

func (ts *Tensor) Must_Std(unbiased bool, del bool) (retVal *Tensor)

func (*Tensor) Must_TestSerializationSubcmul added in v0.3.0

func (ts *Tensor) Must_TestSerializationSubcmul(other *Tensor, del bool) (retVal *Tensor)

func (*Tensor) Must_UnsafeView

func (ts *Tensor) Must_UnsafeView(size []int64, del bool) (retVal *Tensor)

func (*Tensor) Must_Values

func (ts *Tensor) Must_Values(del bool) (retVal *Tensor)

func (*Tensor) Must_Var

func (ts *Tensor) Must_Var(unbiased bool, del bool) (retVal *Tensor)

func (*Tensor) Must__And1

func (ts *Tensor) Must__And1(other *Tensor)

func (*Tensor) Must__And_

func (ts *Tensor) Must__And_(other *Scalar)

func (*Tensor) Must__Iand1

func (ts *Tensor) Must__Iand1(other *Tensor)

func (*Tensor) Must__Iand_

func (ts *Tensor) Must__Iand_(other *Scalar)

func (*Tensor) Must__Ilshift1

func (ts *Tensor) Must__Ilshift1(other *Tensor)

func (*Tensor) Must__Ilshift_

func (ts *Tensor) Must__Ilshift_(other *Scalar)

func (*Tensor) Must__Ior1

func (ts *Tensor) Must__Ior1(other *Tensor)

func (*Tensor) Must__Ior_

func (ts *Tensor) Must__Ior_(other *Scalar)

func (*Tensor) Must__Irshift1

func (ts *Tensor) Must__Irshift1(other *Tensor)

func (*Tensor) Must__Irshift_

func (ts *Tensor) Must__Irshift_(other *Scalar)

func (*Tensor) Must__Ixor1

func (ts *Tensor) Must__Ixor1(other *Tensor)

func (*Tensor) Must__Ixor_

func (ts *Tensor) Must__Ixor_(other *Scalar)

func (*Tensor) Must__Lshift1

func (ts *Tensor) Must__Lshift1(other *Tensor)

func (*Tensor) Must__Lshift_

func (ts *Tensor) Must__Lshift_(other *Scalar)

func (*Tensor) Must__Or1

func (ts *Tensor) Must__Or1(other *Tensor)

func (*Tensor) Must__Or_

func (ts *Tensor) Must__Or_(other *Scalar)

func (*Tensor) Must__Rshift1

func (ts *Tensor) Must__Rshift1(other *Tensor)

func (*Tensor) Must__Rshift_

func (ts *Tensor) Must__Rshift_(other *Scalar)

func (*Tensor) Must__Xor1

func (ts *Tensor) Must__Xor1(other *Tensor)

func (*Tensor) Must__Xor_

func (ts *Tensor) Must__Xor_(other *Scalar)

func (*Tensor) Mv

func (ts *Tensor) Mv(vec *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) MvOut

func (ts *Tensor) MvOut(out *Tensor, vec *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Mvlgamma

func (ts *Tensor) Mvlgamma(p int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Mvlgamma_

func (ts *Tensor) Mvlgamma_(p int64) (err error)

func (*Tensor) NLLLoss

func (ts *Tensor) NLLLoss(target *Tensor, del bool) (retVal *Tensor, err error)

NOTE. `NLLLoss` is a version of `NllLoss` in tensor-generated with default weight, reduction and ignoreIndex

func (*Tensor) Nanquantile added in v0.3.0

func (ts *Tensor) Nanquantile(q float64, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Nanquantile1 added in v0.3.0

func (ts *Tensor) Nanquantile1(q *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) NanquantileOut added in v0.3.0

func (ts *Tensor) NanquantileOut(out *Tensor, q float64, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) NanquantileOut1 added in v0.3.0

func (ts *Tensor) NanquantileOut1(out *Tensor, q *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Nansum added in v0.3.0

func (ts *Tensor) Nansum(dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Nansum1 added in v0.3.0

func (ts *Tensor) Nansum1(dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) NansumOut added in v0.3.0

func (ts *Tensor) NansumOut(out *Tensor, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Narrow

func (ts *Tensor) Narrow(dim int64, start int64, length int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Narrow1

func (ts *Tensor) Narrow1(dim int64, start *Tensor, length int64, del bool) (retVal *Tensor, err error)

func (*Tensor) NarrowCopy

func (ts *Tensor) NarrowCopy(dim int64, start int64, length int64, del bool) (retVal *Tensor, err error)

func (*Tensor) NativeNorm

func (ts *Tensor) NativeNorm(del bool) (retVal *Tensor, err error)

func (*Tensor) NativeNorm1 added in v0.3.0

func (ts *Tensor) NativeNorm1(p *Scalar, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Ne

func (ts *Tensor) Ne(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Ne1

func (ts *Tensor) Ne1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Ne1_

func (ts *Tensor) Ne1_(other *Tensor) (err error)

func (*Tensor) NeOut

func (ts *Tensor) NeOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) NeOut1

func (ts *Tensor) NeOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Ne_

func (ts *Tensor) Ne_(other *Scalar) (err error)

func (*Tensor) Neg

func (ts *Tensor) Neg(del bool) (retVal *Tensor, err error)

func (*Tensor) NegOut

func (ts *Tensor) NegOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Neg_

func (ts *Tensor) Neg_() (err error)

func (*Tensor) Negative added in v0.3.0

func (ts *Tensor) Negative(del bool) (retVal *Tensor, err error)

func (*Tensor) NegativeOut added in v0.3.0

func (ts *Tensor) NegativeOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Negative_ added in v0.3.0

func (ts *Tensor) Negative_() (err error)

func (*Tensor) NewEmpty

func (ts *Tensor) NewEmpty(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device, del bool) (retVal *Tensor, err error)

func (*Tensor) NewFull

func (ts *Tensor) NewFull(size []int64, fillValue *Scalar, optionsKind gotch.DType, optionsDevice gotch.Device, del bool) (retVal *Tensor, err error)

func (*Tensor) NewZeros

func (ts *Tensor) NewZeros(size []int64, optionsKind gotch.DType, optionsDevice gotch.Device, del bool) (retVal *Tensor, err error)

func (*Tensor) Nextafter added in v0.3.0

func (ts *Tensor) Nextafter(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) NextafterOut added in v0.3.0

func (ts *Tensor) NextafterOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Nextafter_ added in v0.3.0

func (ts *Tensor) Nextafter_(other *Tensor) (err error)

func (*Tensor) NllLoss

func (ts *Tensor) NllLoss(target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, del bool) (retVal *Tensor, err error)

func (*Tensor) NllLoss2d

func (ts *Tensor) NllLoss2d(target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, del bool) (retVal *Tensor, err error)

func (*Tensor) NllLoss2dBackward

func (ts *Tensor) NllLoss2dBackward(gradOutput *Tensor, target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, totalWeight *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) NllLoss2dBackwardOut

func (ts *Tensor) NllLoss2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, totalWeight *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) NllLoss2dOut

func (ts *Tensor) NllLoss2dOut(out *Tensor, target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, del bool) (retVal *Tensor, err error)

func (*Tensor) NllLossBackward

func (ts *Tensor) NllLossBackward(gradOutput *Tensor, target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, totalWeight *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) NllLossBackwardOut

func (ts *Tensor) NllLossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, totalWeight *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) NllLossOut

func (ts *Tensor) NllLossOut(out *Tensor, target *Tensor, weight *Tensor, reduction int64, ignoreIndex int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Nonzero

func (ts *Tensor) Nonzero(del bool) (retVal *Tensor, err error)

func (*Tensor) NonzeroNumpy

func (ts *Tensor) NonzeroNumpy() (retVal []Tensor, err error)

tensor *atg_nonzero_numpy(tensor self);

func (*Tensor) NonzeroOut

func (ts *Tensor) NonzeroOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Norm

func (ts *Tensor) Norm(del bool) (retVal *Tensor, err error)

func (*Tensor) Norm1

func (ts *Tensor) Norm1(p *Scalar, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Norm2

func (ts *Tensor) Norm2(p *Scalar, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Norm3

func (ts *Tensor) Norm3(p *Scalar, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) NormOut

func (ts *Tensor) NormOut(out *Tensor, p *Scalar, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) NormOut1

func (ts *Tensor) NormOut1(out *Tensor, p *Scalar, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Normal_

func (ts *Tensor) Normal_(mean float64, std float64) (err error)

func (*Tensor) NotEqual added in v0.3.0

func (ts *Tensor) NotEqual(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) NotEqual1 added in v0.3.0

func (ts *Tensor) NotEqual1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) NotEqual1_ added in v0.3.0

func (ts *Tensor) NotEqual1_(other *Tensor) (err error)

func (*Tensor) NotEqualOut added in v0.3.0

func (ts *Tensor) NotEqualOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) NotEqualOut1 added in v0.3.0

func (ts *Tensor) NotEqualOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) NotEqual_ added in v0.3.0

func (ts *Tensor) NotEqual_(other *Scalar) (err error)

func (*Tensor) NuclearNorm

func (ts *Tensor) NuclearNorm(keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) NuclearNorm1

func (ts *Tensor) NuclearNorm1(dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) NuclearNormOut

func (ts *Tensor) NuclearNormOut(out *Tensor, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) NuclearNormOut1

func (ts *Tensor) NuclearNormOut1(out *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Numel

func (ts *Tensor) Numel() uint

Numel returns the total number of elements stored in a tensor.

func (*Tensor) NumpyT

func (ts *Tensor) NumpyT(del bool) (retVal *Tensor, err error)

func (*Tensor) OneHot

func (ts *Tensor) OneHot(numClasses int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Onehot

func (ts *Tensor) Onehot(labels int64) *Tensor

Onehot converts a tensor to a one-hot encoded version.

If the input has a size [N1, N2, ..., Nk], the returned tensor has a size [N1, ..., Nk, labels]. The returned tensor uses float values. Elements of the input vector are expected to be between 0 and labels-1.

NOTE: There's other `ts.OneHot` and `ts.MustOneHot` generated from Atg C++ API

func (*Tensor) OnesLike

func (ts *Tensor) OnesLike(del bool) (retVal *Tensor, err error)

func (*Tensor) Orgqr

func (ts *Tensor) Orgqr(input2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) OrgqrOut

func (ts *Tensor) OrgqrOut(out *Tensor, input2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Ormqr

func (ts *Tensor) Ormqr(input2 *Tensor, input3 *Tensor, left bool, transpose bool, del bool) (retVal *Tensor, err error)

func (*Tensor) OrmqrOut

func (ts *Tensor) OrmqrOut(out *Tensor, input2 *Tensor, input3 *Tensor, left bool, transpose bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Outer added in v0.3.0

func (ts *Tensor) Outer(vec2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) OuterOut added in v0.3.0

func (ts *Tensor) OuterOut(out *Tensor, vec2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Pdist

func (ts *Tensor) Pdist(p float64, del bool) (retVal *Tensor, err error)

func (*Tensor) Permute

func (ts *Tensor) Permute(dims []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) PinMemory

func (ts *Tensor) PinMemory(del bool) (retVal *Tensor, err error)

func (*Tensor) Pinverse

func (ts *Tensor) Pinverse(rcond float64, del bool) (retVal *Tensor, err error)

func (*Tensor) PixelShuffle

func (ts *Tensor) PixelShuffle(upscaleFactor int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Poisson

func (ts *Tensor) Poisson(del bool) (retVal *Tensor, err error)

func (*Tensor) Polygamma

func (ts *Tensor) Polygamma(n int64, del bool) (retVal *Tensor, err error)

func (*Tensor) PolygammaOut

func (ts *Tensor) PolygammaOut(out *Tensor, n int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Polygamma_

func (ts *Tensor) Polygamma_(n int64) (err error)

func (*Tensor) Pow

func (ts *Tensor) Pow(exponent *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Pow1

func (ts *Tensor) Pow1(exponent *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Pow1_

func (ts *Tensor) Pow1_(exponent *Tensor) (err error)

func (*Tensor) PowOut

func (ts *Tensor) PowOut(out *Tensor, exponent *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) PowOut1

func (ts *Tensor) PowOut1(out *Tensor, exponent *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Pow_

func (ts *Tensor) Pow_(exponent *Scalar) (err error)

func (*Tensor) Prelu

func (ts *Tensor) Prelu(weight *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Print

func (ts *Tensor) Print()

Print prints tensor values to console.

NOTE: it is printed from C and will print ALL elements of tensor with no truncation at all.

func (*Tensor) Prod

func (ts *Tensor) Prod(dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Prod1

func (ts *Tensor) Prod1(dim int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) ProdOut

func (ts *Tensor) ProdOut(out *Tensor, dim int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Put_

func (ts *Tensor) Put_(index *Tensor, source *Tensor, accumulate bool) (err error)

func (*Tensor) QPerChannelScales

func (ts *Tensor) QPerChannelScales(del bool) (retVal *Tensor, err error)

func (*Tensor) QPerChannelZeroPoints

func (ts *Tensor) QPerChannelZeroPoints(del bool) (retVal *Tensor, err error)

func (*Tensor) Quantile added in v0.3.0

func (ts *Tensor) Quantile(q float64, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Quantile1 added in v0.3.0

func (ts *Tensor) Quantile1(q *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) QuantileOut added in v0.3.0

func (ts *Tensor) QuantileOut(out *Tensor, q float64, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) QuantileOut1 added in v0.3.0

func (ts *Tensor) QuantileOut1(out *Tensor, q *Tensor, dim []int64, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) QuantizePerChannel

func (ts *Tensor) QuantizePerChannel(scales *Tensor, zeroPoints *Tensor, axis int64, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) QuantizePerTensor

func (ts *Tensor) QuantizePerTensor(scale float64, zeroPoint int64, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) QuantizedMaxPool1d added in v0.3.0

func (ts *Tensor) QuantizedMaxPool1d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor, err error)

func (*Tensor) QuantizedMaxPool2d

func (ts *Tensor) QuantizedMaxPool2d(kernelSize []int64, stride []int64, padding []int64, dilation []int64, ceilMode bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Rad2deg added in v0.3.0

func (ts *Tensor) Rad2deg(del bool) (retVal *Tensor, err error)

func (*Tensor) Rad2degOut added in v0.3.0

func (ts *Tensor) Rad2degOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Rad2deg_ added in v0.3.0

func (ts *Tensor) Rad2deg_() (err error)

func (*Tensor) RandLike

func (ts *Tensor) RandLike(del bool) (retVal *Tensor, err error)

func (*Tensor) RandintLike

func (ts *Tensor) RandintLike(high int64, del bool) (retVal *Tensor, err error)

func (*Tensor) RandintLike1

func (ts *Tensor) RandintLike1(low int64, high int64, del bool) (retVal *Tensor, err error)

func (*Tensor) RandnLike

func (ts *Tensor) RandnLike(del bool) (retVal *Tensor, err error)

func (*Tensor) Random1_

func (ts *Tensor) Random1_(to int64) (err error)

func (*Tensor) Random2

func (ts *Tensor) Random2(from int64, to []int64) (err error)

func (*Tensor) Random_

func (ts *Tensor) Random_() (err error)

func (*Tensor) Real

func (ts *Tensor) Real(del bool) (retVal *Tensor, err error)

func (*Tensor) Reciprocal

func (ts *Tensor) Reciprocal(del bool) (retVal *Tensor, err error)

func (*Tensor) ReciprocalOut

func (ts *Tensor) ReciprocalOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Reciprocal_

func (ts *Tensor) Reciprocal_() (err error)

func (*Tensor) ReflectionPad1d

func (ts *Tensor) ReflectionPad1d(padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReflectionPad1dBackward

func (ts *Tensor) ReflectionPad1dBackward(gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReflectionPad1dBackwardOut

func (ts *Tensor) ReflectionPad1dBackwardOut(gradInput *Tensor, gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReflectionPad1dOut

func (ts *Tensor) ReflectionPad1dOut(out *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReflectionPad2d

func (ts *Tensor) ReflectionPad2d(padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReflectionPad2dBackward

func (ts *Tensor) ReflectionPad2dBackward(gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReflectionPad2dBackwardOut

func (ts *Tensor) ReflectionPad2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReflectionPad2dOut

func (ts *Tensor) ReflectionPad2dOut(out *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Relu

func (ts *Tensor) Relu(del bool) (retVal *Tensor, err error)

func (*Tensor) Relu_

func (ts *Tensor) Relu_() (err error)

func (*Tensor) Remainder

func (ts *Tensor) Remainder(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Remainder1

func (ts *Tensor) Remainder1(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Remainder1_

func (ts *Tensor) Remainder1_(other *Tensor) (err error)

func (*Tensor) RemainderOut

func (ts *Tensor) RemainderOut(out *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) RemainderOut1

func (ts *Tensor) RemainderOut1(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Remainder_

func (ts *Tensor) Remainder_(other *Scalar) (err error)

func (*Tensor) Renorm

func (ts *Tensor) Renorm(p *Scalar, dim int64, maxnorm *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) RenormOut

func (ts *Tensor) RenormOut(out *Tensor, p *Scalar, dim int64, maxnorm *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Renorm_

func (ts *Tensor) Renorm_(p *Scalar, dim int64, maxnorm *Scalar) (err error)

func (*Tensor) Repeat

func (ts *Tensor) Repeat(repeats []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) RepeatInterleave1

func (ts *Tensor) RepeatInterleave1(repeats *Tensor, dim []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) RepeatInterleave2

func (ts *Tensor) RepeatInterleave2(repeats int64, dim []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReplicationPad1d

func (ts *Tensor) ReplicationPad1d(padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReplicationPad1dBackward

func (ts *Tensor) ReplicationPad1dBackward(gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReplicationPad1dBackwardOut

func (ts *Tensor) ReplicationPad1dBackwardOut(gradInput *Tensor, gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReplicationPad1dOut

func (ts *Tensor) ReplicationPad1dOut(out *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReplicationPad2d

func (ts *Tensor) ReplicationPad2d(padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReplicationPad2dBackward

func (ts *Tensor) ReplicationPad2dBackward(gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReplicationPad2dBackwardOut

func (ts *Tensor) ReplicationPad2dBackwardOut(gradInput *Tensor, gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReplicationPad2dOut

func (ts *Tensor) ReplicationPad2dOut(out *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReplicationPad3d

func (ts *Tensor) ReplicationPad3d(padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReplicationPad3dBackward

func (ts *Tensor) ReplicationPad3dBackward(gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReplicationPad3dBackwardOut

func (ts *Tensor) ReplicationPad3dBackwardOut(gradInput *Tensor, gradOutput *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReplicationPad3dOut

func (ts *Tensor) ReplicationPad3dOut(out *Tensor, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) RequiresGrad

func (ts *Tensor) RequiresGrad() (bool, error)

RequiresGrad returns true if gradient are currently tracked for this tensor.

func (*Tensor) RequiresGrad_

func (ts *Tensor) RequiresGrad_(requiresGrad bool) (err error)

func (*Tensor) Reshape

func (ts *Tensor) Reshape(shape []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ReshapeAs

func (ts *Tensor) ReshapeAs(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) ResizeAs_

func (ts *Tensor) ResizeAs_(theTemplate *Tensor) (err error)

func (*Tensor) Resize_

func (ts *Tensor) Resize_(size []int64) (err error)

func (*Tensor) Rfft

func (ts *Tensor) Rfft(signalNdim int64, normalized bool, onesided bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Roll

func (ts *Tensor) Roll(shifts []int64, dims []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Rot90

func (ts *Tensor) Rot90(k int64, dims []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Round

func (ts *Tensor) Round(del bool) (retVal *Tensor, err error)

func (*Tensor) RoundOut

func (ts *Tensor) RoundOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Round_

func (ts *Tensor) Round_() (err error)

func (*Tensor) Rrelu

func (ts *Tensor) Rrelu(training bool, del bool) (retVal *Tensor, err error)

func (*Tensor) RreluWithNoise

func (ts *Tensor) RreluWithNoise(noise *Tensor, training bool, del bool) (retVal *Tensor, err error)

func (*Tensor) RreluWithNoiseBackward

func (ts *Tensor) RreluWithNoiseBackward(gradOutput *Tensor, noise *Tensor, lower *Scalar, upper *Scalar, training bool, selfIsResult bool, del bool) (retVal *Tensor, err error)

func (*Tensor) RreluWithNoiseOut

func (ts *Tensor) RreluWithNoiseOut(out *Tensor, noise *Tensor, training bool, del bool) (retVal *Tensor, err error)

func (*Tensor) RreluWithNoise_

func (ts *Tensor) RreluWithNoise_(noise *Tensor, training bool) (err error)

func (*Tensor) Rrelu_

func (ts *Tensor) Rrelu_(training bool) (err error)

func (*Tensor) Rsqrt

func (ts *Tensor) Rsqrt(del bool) (retVal *Tensor, err error)

func (*Tensor) RsqrtOut

func (ts *Tensor) RsqrtOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Rsqrt_

func (ts *Tensor) Rsqrt_() (err error)

func (*Tensor) Rsub

func (ts *Tensor) Rsub(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Rsub1

func (ts *Tensor) Rsub1(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Save

func (ts *Tensor) Save(path string) error

Save saves a tensor to a file.

func (*Tensor) Scatter

func (ts *Tensor) Scatter(dim int64, index *Tensor, src *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Scatter1

func (ts *Tensor) Scatter1(dim int64, index *Tensor, value *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Scatter1_

func (ts *Tensor) Scatter1_(dim int64, index *Tensor, value *Scalar) (err error)

func (*Tensor) Scatter2 added in v0.3.0

func (ts *Tensor) Scatter2(dim int64, index *Tensor, src *Tensor, reduce string) (err error)

func (*Tensor) Scatter3 added in v0.3.0

func (ts *Tensor) Scatter3(dim int64, index *Tensor, value *Scalar, reduce string) (err error)

func (*Tensor) ScatterAdd

func (ts *Tensor) ScatterAdd(dim int64, index *Tensor, src *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) ScatterAdd_

func (ts *Tensor) ScatterAdd_(dim int64, index *Tensor, src *Tensor) (err error)

func (*Tensor) Scatter_

func (ts *Tensor) Scatter_(dim int64, index *Tensor, src *Tensor) (err error)

func (*Tensor) Searchsorted added in v0.3.0

func (ts *Tensor) Searchsorted(sortedSequence *Tensor, outInt32 bool, right bool, del bool) (retVal *Tensor, err error)

func (*Tensor) SearchsortedOut added in v0.3.0

func (ts *Tensor) SearchsortedOut(out *Tensor, sortedSequence *Tensor, outInt32 bool, right bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Select

func (ts *Tensor) Select(dim int64, index int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Selu

func (ts *Tensor) Selu(del bool) (retVal *Tensor, err error)

func (*Tensor) Selu_

func (ts *Tensor) Selu_() (err error)

func (*Tensor) Set1_

func (ts *Tensor) Set1_(source *Tensor) (err error)

func (*Tensor) SetRequiresGrad

func (ts *Tensor) SetRequiresGrad(r bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Set_

func (ts *Tensor) Set_() (err error)

func (*Tensor) Sgn added in v0.3.0

func (ts *Tensor) Sgn(del bool) (retVal *Tensor, err error)

func (*Tensor) SgnOut added in v0.3.0

func (ts *Tensor) SgnOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Sgn_ added in v0.3.0

func (ts *Tensor) Sgn_() (err error)

func (*Tensor) ShallowClone

func (ts *Tensor) ShallowClone() (*Tensor, error)

ShallowClone returns a new tensor that share storage with the input tensor.

func (*Tensor) Sigmoid

func (ts *Tensor) Sigmoid(del bool) (retVal *Tensor, err error)

func (*Tensor) SigmoidOut

func (ts *Tensor) SigmoidOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Sigmoid_

func (ts *Tensor) Sigmoid_() (err error)

func (*Tensor) Sign

func (ts *Tensor) Sign(del bool) (retVal *Tensor, err error)

func (*Tensor) SignOut

func (ts *Tensor) SignOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Sign_

func (ts *Tensor) Sign_() (err error)

func (*Tensor) Signbit added in v0.3.0

func (ts *Tensor) Signbit(del bool) (retVal *Tensor, err error)

func (*Tensor) SignbitOut added in v0.3.0

func (ts *Tensor) SignbitOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Silu added in v0.3.0

func (ts *Tensor) Silu(del bool) (retVal *Tensor, err error)

func (*Tensor) SiluBackward added in v0.3.0

func (ts *Tensor) SiluBackward(gradOutput *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) SiluOut added in v0.3.0

func (ts *Tensor) SiluOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Silu_ added in v0.3.0

func (ts *Tensor) Silu_() (err error)

func (*Tensor) Sin

func (ts *Tensor) Sin(del bool) (retVal *Tensor, err error)

func (*Tensor) SinOut

func (ts *Tensor) SinOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Sin_

func (ts *Tensor) Sin_() (err error)

func (*Tensor) Sinh

func (ts *Tensor) Sinh(del bool) (retVal *Tensor, err error)

func (*Tensor) SinhOut

func (ts *Tensor) SinhOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Sinh_

func (ts *Tensor) Sinh_() (err error)

func (*Tensor) Size

func (ts *Tensor) Size() ([]int64, error)

Size return shape of the tensor

NOTE: C++ libtorch calls at_shape() -> t.sizes() And returns a slice of sizes or shape using given pointer to that slice.

func (*Tensor) Size1

func (ts *Tensor) Size1() (int64, error)

Size1 returns the tensor size for 1D tensors.

func (*Tensor) Size2

func (ts *Tensor) Size2() ([]int64, error)

Size2 returns the tensor size for 2D tensors.

func (*Tensor) Size3

func (ts *Tensor) Size3() ([]int64, error)

Size3 returns the tensor size for 3D tensors.

func (*Tensor) Size4

func (ts *Tensor) Size4() ([]int64, error)

Size4 returns the tensor size for 4D tensors.

func (*Tensor) Slice

func (ts *Tensor) Slice(dim int64, start int64, end int64, step int64, del bool) (retVal *Tensor, err error)

func (*Tensor) SlowConv3d

func (ts *Tensor) SlowConv3d(weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) SlowConv3dOut

func (ts *Tensor) SlowConv3dOut(out *Tensor, weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) SlowConvDilated2d

func (ts *Tensor) SlowConvDilated2d(weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, dilation []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) SlowConvDilated3d

func (ts *Tensor) SlowConvDilated3d(weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, dilation []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) SlowConvTranspose2d

func (ts *Tensor) SlowConvTranspose2d(weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, dilation []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) SlowConvTranspose2dOut

func (ts *Tensor) SlowConvTranspose2dOut(out *Tensor, weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, dilation []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) SlowConvTranspose3d

func (ts *Tensor) SlowConvTranspose3d(weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, dilation []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) SlowConvTranspose3dOut

func (ts *Tensor) SlowConvTranspose3dOut(out *Tensor, weight *Tensor, kernelSize []int64, bias *Tensor, stride []int64, padding []int64, outputPadding []int64, dilation []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Smm

func (ts *Tensor) Smm(mat2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) SmoothL1Loss

func (ts *Tensor) SmoothL1Loss(target *Tensor, reduction int64, beta float64, del bool) (retVal *Tensor, err error)

func (*Tensor) SmoothL1LossBackward

func (ts *Tensor) SmoothL1LossBackward(gradOutput *Tensor, target *Tensor, reduction int64, beta float64, del bool) (retVal *Tensor, err error)

func (*Tensor) SmoothL1LossBackwardOut

func (ts *Tensor) SmoothL1LossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, reduction int64, beta float64, del bool) (retVal *Tensor, err error)

func (*Tensor) SmoothL1LossOut

func (ts *Tensor) SmoothL1LossOut(out *Tensor, target *Tensor, reduction int64, beta float64, del bool) (retVal *Tensor, err error)

func (*Tensor) SoftMarginLoss

func (ts *Tensor) SoftMarginLoss(target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) SoftMarginLossBackward

func (ts *Tensor) SoftMarginLossBackward(gradOutput *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) SoftMarginLossBackwardOut

func (ts *Tensor) SoftMarginLossBackwardOut(gradInput *Tensor, gradOutput *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) SoftMarginLossOut

func (ts *Tensor) SoftMarginLossOut(out *Tensor, target *Tensor, reduction int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Softmax

func (ts *Tensor) Softmax(dim int64, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Softplus

func (ts *Tensor) Softplus(del bool) (retVal *Tensor, err error)

func (*Tensor) SoftplusBackward

func (ts *Tensor) SoftplusBackward(gradOutput *Tensor, beta *Scalar, threshold *Scalar, output *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) SoftplusBackwardOut

func (ts *Tensor) SoftplusBackwardOut(gradInput *Tensor, gradOutput *Tensor, beta *Scalar, threshold *Scalar, output *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) SoftplusOut

func (ts *Tensor) SoftplusOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Softshrink

func (ts *Tensor) Softshrink(del bool) (retVal *Tensor, err error)

func (*Tensor) SoftshrinkBackward

func (ts *Tensor) SoftshrinkBackward(gradOutput *Tensor, lambd *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) SoftshrinkBackwardOut

func (ts *Tensor) SoftshrinkBackwardOut(gradInput *Tensor, gradOutput *Tensor, lambd *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) SoftshrinkOut

func (ts *Tensor) SoftshrinkOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) SparseMask

func (ts *Tensor) SparseMask(mask *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) SparseResizeAndClear_

func (ts *Tensor) SparseResizeAndClear_(size []int64, sparseDim int64, denseDim int64) (err error)

func (*Tensor) SparseResize_

func (ts *Tensor) SparseResize_(size []int64, sparseDim int64, denseDim int64) (err error)

func (*Tensor) Split

func (ts *Tensor) Split(splitSize, dim int64) (retVal []Tensor, err error)

Split splits tensor into chunks

Parameters:

  • splitSize – size of a single chunk
  • dim – dimension along which to split the tensor.

Ref. https://pytorch.org/docs/stable/generated/torch.split.html

func (*Tensor) SplitWithSizes

func (ts *Tensor) SplitWithSizes(splitSizes []int64, dim int64) (retVal []Tensor, err error)

SplitWithSizes splits tensor into chunks

Parameters:

  • splitSizes – slice of sizes for each chunk
  • dim – dimension along which to split the tensor.

Ref. https://pytorch.org/docs/stable/generated/torch.split.html

func (*Tensor) Sqrt

func (ts *Tensor) Sqrt(del bool) (retVal *Tensor, err error)

func (*Tensor) SqrtOut

func (ts *Tensor) SqrtOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Sqrt_

func (ts *Tensor) Sqrt_() (err error)

func (*Tensor) Square

func (ts *Tensor) Square(del bool) (retVal *Tensor, err error)

func (*Tensor) Square_

func (ts *Tensor) Square_() (err error)

func (*Tensor) Squeeze

func (ts *Tensor) Squeeze(del bool) (retVal *Tensor, err error)

func (*Tensor) Squeeze1

func (ts *Tensor) Squeeze1(dim int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Squeeze1_

func (ts *Tensor) Squeeze1_(dim int64) (err error)

func (*Tensor) Squeeze_

func (ts *Tensor) Squeeze_() (err error)

func (*Tensor) Sspaddmm

func (ts *Tensor) Sspaddmm(mat1 *Tensor, mat2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) SspaddmmOut

func (ts *Tensor) SspaddmmOut(out *Tensor, mat1 *Tensor, mat2 *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Std

func (ts *Tensor) Std(unbiased bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Std1

func (ts *Tensor) Std1(dim []int64, unbiased bool, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) StdOut

func (ts *Tensor) StdOut(out *Tensor, dim []int64, unbiased bool, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Stft

func (ts *Tensor) Stft(nFft int64, hopLength []int64, winLength []int64, window *Tensor, normalized bool, onesided bool, returnComplex bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Sub

func (ts *Tensor) Sub(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Sub1

func (ts *Tensor) Sub1(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Sub1_

func (ts *Tensor) Sub1_(other *Scalar) (err error)

func (*Tensor) SubOut

func (ts *Tensor) SubOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Sub_

func (ts *Tensor) Sub_(other *Tensor) (err error)

func (*Tensor) Subtract added in v0.3.0

func (ts *Tensor) Subtract(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Subtract1 added in v0.3.0

func (ts *Tensor) Subtract1(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Subtract1_ added in v0.3.0

func (ts *Tensor) Subtract1_(other *Scalar) (err error)

func (*Tensor) SubtractOut added in v0.3.0

func (ts *Tensor) SubtractOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Subtract_ added in v0.3.0

func (ts *Tensor) Subtract_(other *Tensor) (err error)

func (*Tensor) Sum

func (ts *Tensor) Sum(dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Sum1

func (ts *Tensor) Sum1(dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) SumOut

func (ts *Tensor) SumOut(out *Tensor, dim []int64, keepdim bool, dtype gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) SumToSize

func (ts *Tensor) SumToSize(size []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Swish

func (ts *Tensor) Swish() *Tensor

func (*Tensor) T

func (ts *Tensor) T(del bool) (retVal *Tensor, err error)

func (*Tensor) T_

func (ts *Tensor) T_() (err error)

func (*Tensor) Take

func (ts *Tensor) Take(index *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) TakeOut

func (ts *Tensor) TakeOut(out *Tensor, index *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Tan

func (ts *Tensor) Tan(del bool) (retVal *Tensor, err error)

func (*Tensor) TanOut

func (ts *Tensor) TanOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Tan_

func (ts *Tensor) Tan_() (err error)

func (*Tensor) Tanh

func (ts *Tensor) Tanh(del bool) (retVal *Tensor, err error)

func (*Tensor) TanhOut

func (ts *Tensor) TanhOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Tanh_

func (ts *Tensor) Tanh_() (err error)

func (*Tensor) Tensordot

func (ts *Tensor) Tensordot(other *Tensor, dimsSelf []int64, dimsOther []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Threshold

func (ts *Tensor) Threshold(threshold *Scalar, value *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) ThresholdBackward

func (ts *Tensor) ThresholdBackward(gradOutput *Tensor, threshold *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) ThresholdOut

func (ts *Tensor) ThresholdOut(out *Tensor, threshold *Scalar, value *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) Threshold_

func (ts *Tensor) Threshold_(threshold *Scalar, value *Scalar) (err error)

func (*Tensor) To

func (ts *Tensor) To(device gotch.Device, del bool) (retVal *Tensor, err error)

func (*Tensor) To1

func (ts *Tensor) To1(optionsKind gotch.DType, optionsDevice gotch.Device, nonBlocking bool, copy bool, del bool) (retVal *Tensor, err error)

func (*Tensor) To2

func (ts *Tensor) To2(dtype gotch.DType, nonBlocking bool, copy bool, del bool) (retVal *Tensor, err error)

func (*Tensor) To3

func (ts *Tensor) To3(other *Tensor, nonBlocking bool, copy bool, del bool) (retVal *Tensor, err error)

func (*Tensor) To4

func (ts *Tensor) To4(device gotch.Device, dtype gotch.DType, nonBlocking bool, copy bool, del bool) (retVal *Tensor, err error)

func (*Tensor) ToDense

func (ts *Tensor) ToDense(del bool) (retVal *Tensor, err error)

func (*Tensor) ToMkldnn

func (ts *Tensor) ToMkldnn(del bool) (retVal *Tensor, err error)

func (*Tensor) ToSlice added in v0.3.2

func (ts *Tensor) ToSlice() reflect.Value

func (*Tensor) ToSparse

func (ts *Tensor) ToSparse(del bool) (retVal *Tensor, err error)

func (*Tensor) ToSparse1

func (ts *Tensor) ToSparse1(sparseDim int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ToString

func (ts *Tensor) ToString(lw int64) (string, error)

ToString returns a string representation for the tensor.

lw : line width (size) NOTE: The representation will contain all the tensor element hence may be huge for large tensors.

func (*Tensor) TopK

func (ts *Tensor) TopK(k int64, dim int64, largest bool, sorted bool) (ts1, ts2 *Tensor, err error)

func (*Tensor) Totype

func (ts *Tensor) Totype(scalarType gotch.DType, del bool) (retVal *Tensor, err error)

func (*Tensor) Trace

func (ts *Tensor) Trace(del bool) (retVal *Tensor, err error)

func (*Tensor) Transpose

func (ts *Tensor) Transpose(dim0 int64, dim1 int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Transpose_

func (ts *Tensor) Transpose_(dim0 int64, dim1 int64) (err error)

func (*Tensor) Tril

func (ts *Tensor) Tril(diagonal int64, del bool) (retVal *Tensor, err error)

func (*Tensor) TrilOut

func (ts *Tensor) TrilOut(out *Tensor, diagonal int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Tril_

func (ts *Tensor) Tril_(diagonal int64) (err error)

func (*Tensor) Triu

func (ts *Tensor) Triu(diagonal int64, del bool) (retVal *Tensor, err error)

func (*Tensor) TriuOut

func (ts *Tensor) TriuOut(out *Tensor, diagonal int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Triu_

func (ts *Tensor) Triu_(diagonal int64) (err error)

func (*Tensor) TrueDivide

func (ts *Tensor) TrueDivide(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) TrueDivide1

func (ts *Tensor) TrueDivide1(other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) TrueDivide1_

func (ts *Tensor) TrueDivide1_(other *Scalar) (err error)

func (*Tensor) TrueDivideOut

func (ts *Tensor) TrueDivideOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) TrueDivide_

func (ts *Tensor) TrueDivide_(other *Tensor) (err error)

func (*Tensor) Trunc

func (ts *Tensor) Trunc(del bool) (retVal *Tensor, err error)

func (*Tensor) TruncOut

func (ts *Tensor) TruncOut(out *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Trunc_

func (ts *Tensor) Trunc_() (err error)

func (*Tensor) TypeAs

func (ts *Tensor) TypeAs(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Unbind

func (ts *Tensor) Unbind(dim int64) (retVal []Tensor, err error)

tensor *atg_unbind(tensor self, int64_t dim);

func (*Tensor) Unflatten added in v0.3.0

func (ts *Tensor) Unflatten(dim int64, sizes []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Unfold

func (ts *Tensor) Unfold(dimension int64, size int64, step int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Uniform_

func (ts *Tensor) Uniform_(from float64, to float64) (err error)

func (*Tensor) Unsqueeze

func (ts *Tensor) Unsqueeze(dim int64, del bool) (retVal *Tensor, err error)

func (*Tensor) Unsqueeze_

func (ts *Tensor) Unsqueeze_(dim int64) (err error)

func (*Tensor) UpsampleBicubic2d

func (ts *Tensor) UpsampleBicubic2d(outputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleBicubic2dOut

func (ts *Tensor) UpsampleBicubic2dOut(out *Tensor, outputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleBilinear2d

func (ts *Tensor) UpsampleBilinear2d(outputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleBilinear2dOut

func (ts *Tensor) UpsampleBilinear2dOut(out *Tensor, outputSize []int64, alignCorners bool, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleLinear1d

func (ts *Tensor) UpsampleLinear1d(outputSize []int64, alignCorners bool, scales []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleLinear1dOut

func (ts *Tensor) UpsampleLinear1dOut(out *Tensor, outputSize []int64, alignCorners bool, scales []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleNearest1d

func (ts *Tensor) UpsampleNearest1d(outputSize []int64, scales []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleNearest1dOut

func (ts *Tensor) UpsampleNearest1dOut(out *Tensor, outputSize []int64, scales []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleNearest2d

func (ts *Tensor) UpsampleNearest2d(outputSize []int64, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleNearest2dOut

func (ts *Tensor) UpsampleNearest2dOut(out *Tensor, outputSize []int64, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleNearest3d

func (ts *Tensor) UpsampleNearest3d(outputSize []int64, scalesD []float64, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleNearest3dOut

func (ts *Tensor) UpsampleNearest3dOut(out *Tensor, outputSize []int64, scalesD []float64, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleTrilinear3d

func (ts *Tensor) UpsampleTrilinear3d(outputSize []int64, alignCorners bool, scalesD []float64, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) UpsampleTrilinear3dOut

func (ts *Tensor) UpsampleTrilinear3dOut(out *Tensor, outputSize []int64, alignCorners bool, scalesD []float64, scalesH []float64, scalesW []float64, del bool) (retVal *Tensor, err error)

func (*Tensor) Vals

func (ts *Tensor) Vals() interface{}

Vals returns tensor values in a slice NOTE: need a type insersion to get runtime type E.g. res := xs.Vals().([]int64)

func (*Tensor) ValueGo added in v0.3.2

func (ts *Tensor) ValueGo() interface{}

func (*Tensor) Values

func (ts *Tensor) Values(del bool) (retVal *Tensor, err error)

func (*Tensor) Var

func (ts *Tensor) Var(unbiased bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Var1

func (ts *Tensor) Var1(dim []int64, unbiased bool, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) VarOut

func (ts *Tensor) VarOut(out *Tensor, dim []int64, unbiased bool, keepdim bool, del bool) (retVal *Tensor, err error)

func (*Tensor) Vdot added in v0.3.0

func (ts *Tensor) Vdot(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) VdotOut added in v0.3.0

func (ts *Tensor) VdotOut(out *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) View

func (ts *Tensor) View(size []int64, del bool) (retVal *Tensor, err error)

func (*Tensor) ViewAs

func (ts *Tensor) ViewAs(other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) ViewAsComplex added in v0.3.0

func (ts *Tensor) ViewAsComplex(del bool) (retVal *Tensor, err error)

func (*Tensor) ViewAsReal added in v0.3.0

func (ts *Tensor) ViewAsReal(del bool) (retVal *Tensor, err error)

func (*Tensor) Where1

func (ts *Tensor) Where1(condition *Tensor, other *Tensor, del bool) (retVal *Tensor, err error)

func (*Tensor) Where3 added in v0.3.0

func (ts *Tensor) Where3(condition *Tensor, other *Scalar, del bool) (retVal *Tensor, err error)

func (*Tensor) ZeroGrad

func (ts *Tensor) ZeroGrad()

ZeroGrad zeroes the gradient tensor attached to this tensor if defined.

func (*Tensor) ZeroPad2d

func (ts *Tensor) ZeroPad2d(left, right, top, bottom int64, del bool) (*Tensor, error)

func (*Tensor) Zero_

func (ts *Tensor) Zero_() (err error)

func (*Tensor) ZerosLike

func (ts *Tensor) ZerosLike(del bool) (retVal *Tensor, err error)

type TensorIndexer

type TensorIndexer interface{}

TensorIndexer is an interface which defines method `From` for any type to fulfill to become an tensor indexer

type TextData

type TextData struct {
	Data         *Tensor // frequency (occurence) of byte value from input text
	CharForLabel []rune  // unique rune values from input text
}

TextData represent text data in tensor of runes (uint8) and its corresponding string

func NewTextData

func NewTextData(filename string) (*TextData, error)

NewTextData creates a text dataset from a file

It reads text input from file to `[]byte` buffer - Loops over each byte - first byte will be labelled `0` - next byte if exist will be labelled with existing label (index), otherwise will labelled with new label(index) Data: tensor of labels CharForLabel: []rune (unique runes from text input)

func (*TextData) CloneData

func (td *TextData) CloneData() *Tensor

Data returns a shallow copy of the data.

func (*TextData) IterShuffle

func (td *TextData) IterShuffle(seqLen int64, batchSize int64) *TextDataIter

IterShuffle returns a batch iterator over the dataset. Each sample is made of seq_len characters.

func (*TextData) LabelForChar

func (td *TextData) LabelForChar(label int64) rune

LabelForChar returns a corresponding `char` (rune) for specified label input

func (*TextData) Labels

func (td *TextData) Labels() (retVal int64)

Labels returns the number of different `character` (rune) used by the dataset.

type TextDataIter

type TextDataIter struct {
	Data       *Tensor
	SeqLen     int64
	BatchIndex int64
	BatchSize  int64
	Indexes    *Tensor
	IndexesLen int64
}

TextDataIter is a text data interator

func (*TextDataIter) Next

func (tdi *TextDataIter) Next() (*Tensor, bool)

Next implements iterator for TextDataIter

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL