sealed trait Device extends AnyRef
Represents a device where tensors are stored and tensor operations are executed
- Self Type
- Device
- Alphabetic
- By Inheritance
- Device
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Abstract Value Members
- abstract def measureTime[A](f: => A): (A, Long)
- abstract def options[S](precision: FloatingPointPrecision)(implicit arg0: Sc[S]): STenOptions
- abstract def setSeed(seed: Long): Unit
- abstract def to[S](t: STenOptions)(implicit arg0: Sc[S]): STenOptions
- abstract def to(t: Tensor): Tensor
Concrete Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def allocateBuffers[S](size: Long, options: STenOptions)(implicit arg0: Sc[S]): BufferPair
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def to[S](t: STen)(implicit arg0: Sc[S]): STen
- def toBatched[S](tensors: Seq[STen], buffers: BufferPair)(implicit arg0: Sc[S]): Seq[STen]
Copies tensors to this device in a single cross device copy.
Copies tensors to this device in a single cross device copy. Data is copied via a buffer pair which consists of a source and a destinatin buffer. srcBuffer is supposed to be on the source device. dstBuffer has to be on
this
device. Tensors are first copied to the srcBuffer, then the srcBuffer is copied to dstBuffer, then the dstBuffer is split into views.All tensors must have the same data type.
Might make sense to pin the srcBuffer.
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- def withOtherStream[A](synchronizeBefore: Boolean, synchronizeAfter: Boolean)(f: => A): A
Executes f on a new stream
Executes f on a new stream
f must not switch to other threads
Restores the stream to the original stream Optionally synchronizes the host before and/or after f
- Annotations
- @nowarn()
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated
(Since version 9)