object TensorLogger extends Serializable
Utility to periodically log active tensors See lamp.data.TensorLogger#start
- Alphabetic
- By Inheritance
- TensorLogger
- Serializable
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
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
- 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()
- def detailAllTensorOptions(logger: (String) => Unit): Unit
- def detailAllTensors(logger: (String) => Unit): Unit
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def formatLine(data: TensorTraceData): String
- def formatStackTrace(data: TensorTraceData): String
- 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
- def logTensorOptions(logger: (String) => Unit, filter: (TensorTraceData, Double) => Boolean, detailMinMs: Double, detailMaxMs: Double, detailNum: Int): Unit
- def logTensors(logger: (String) => Unit, filter: (TensorTraceData, Double) => Boolean, detailMinMs: Double, detailMaxMs: Double, detailNum: Int): Unit
- def makeLog(nanoTime: Long, data: Seq[TensorTraceData], filter: (TensorTraceData, Double) => Boolean, detailMinMs: Double, detailMaxMs: Double, detailNum: Int): String
- def makeStatistic(nanoTime: Long, actives: Seq[TensorTraceData])(filter: (TensorTraceData, Double) => Boolean): (List[(Double, Double, Int)], Seq[(TensorTraceData, Double)], Map[Boolean, Long])
- 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()
- def queryActiveTensorOptions(): Vector[TensorTraceData]
- def queryActiveTensors(): Vector[TensorTraceData]
- def start(frequency: FiniteDuration = 5 seconds)(logger: (String) => Unit, filter: (TensorTraceData, Double) => Boolean, detailMinMs: Double, detailMaxMs: Double, detailNum: Int): TensorLogger
Log active tensors with a given frequency
Log active tensors with a given frequency
The log string itself consists of a summary statistics of active tensors and a list of detailed information on some number of active tensors. The detailed information shows the stack trace where the tensor was allocated. The tensors eligible for detail are specified by a filter on their lifetime.
This method will spawn a new Thread, which repeatedly logs and sleeps until not canceled.
- frequency
the frequency with which the logging will occur
- logger
a side effecting lambda which executes the log
- filter
a predicate taking some information about the tensor and the lifetime of the tensor in milliseconds
- detailMinMs
minimum lifetime in milliseconds for a tensor to be eligible for detailed logging
- detailMaxMs
maximum lifetime in milliseconds for a tensor to be eligible for detailed logging
- detailNum
max number of tensors in the detailed section
- returns
an instance of TensorLogger whose sole purpose is its
cancel()
method which stops the logger
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- 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])
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated
(Since version 9)