TensorModule

torch.nn.modules.TensorModule
trait TensorModule[D <: DType] extends Module, Tensor[D] => Tensor[D]

Transforms a single tensor into another one of the same type.

Attributes

Source
Module.scala
Graph
Supertypes
trait Tensor[D] => Tensor[D]
class Module
class Object
trait Matchable
class Any
Known subtypes
class BasicBlock[D]
class Bottleneck[D]
class LogSoftmax[D]
class ReLU[D]
class Softmax[D]
class Tanh[D]
class BatchNorm1d[ParamType]
class BatchNorm2d[ParamType]
class ModuleList[D]
class Sequential[D]
class Conv2d[ParamType]
class Flatten[D]
class Identity[D]
class Linear[ParamType]
class GroupNorm[ParamType]
class LayerNorm[ParamType]
class MaxPool2d[D]
class Dropout[ParamType]
Show all

Members list

Value members

Concrete methods

override def toString(): String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns

a string representation of the object.

Definition Classes
Function1 -> Module -> Any
Source
Module.scala

Inherited methods

def andThen[A](g: Tensor[D] => A): T1 => A

Attributes

Inherited from:
Function1
def apply(v1: Tensor[D]): R

Attributes

Inherited from:
Function1
def apply(fn: Module => Unit): Module.this.type

Attributes

Inherited from:
Module
Source
Module.scala
def compose[A](g: A => Tensor[D]): A => R

Attributes

Inherited from:
Function1
def eval(): Unit

Attributes

Inherited from:
Module
Source
Module.scala
def hasBias(): Boolean

Attributes

Inherited from:
Module
Source
Module.scala

Attributes

Inherited from:
Module
Source
Module.scala
def load(inputArchive: InputArchive): Unit

Attributes

Inherited from:
Module
Source
Module.scala

Attributes

Inherited from:
Module
Source
Module.scala

Attributes

Inherited from:
Module
Source
Module.scala

Attributes

Inherited from:
Module
Source
Module.scala

Attributes

Inherited from:
Module
Source
Module.scala

Attributes

Inherited from:
Module
Source
Module.scala

Attributes

Inherited from:
Module
Source
Module.scala

Attributes

Inherited from:
Module
Source
Module.scala

Attributes

Inherited from:
Module
Source
Module.scala
def parameters: Seq[Tensor[_]]

Attributes

Inherited from:
Module
Source
Module.scala
def register[M <: Module](child: M, n: String)(using name: Name): M

Attributes

Inherited from:
Module
Source
Module.scala

Adds a buffer to the module.

Adds a buffer to the module.

Attributes

Inherited from:
Module
Source
Module.scala
def registerBuffer[D <: DType](t: Tensor[D], n: String)(using name: Name): Tensor[D]

Attributes

Inherited from:
Module
Source
Module.scala
def registerModule[M <: Module](child: M, n: String)(using name: Name): M

Attributes

Inherited from:
Module
Source
Module.scala
def registerParameter[D <: DType](t: Tensor[D], requiresGrad: Boolean, n: String)(using name: Name): Tensor[D]

Attributes

Inherited from:
Module
Source
Module.scala
def save(outputArchive: OutputArchive): Unit

Attributes

Inherited from:
Module
Source
Module.scala

Attributes

Inherited from:
Module
Source
Module.scala
def to(device: Device): Module.this.type

Attributes

Inherited from:
Module
Source
Module.scala
def train(on: Boolean): Unit

Attributes

Inherited from:
Module
Source
Module.scala