TrainingHistory

class TrainingHistory

Contains all recorded batch events as a list of BatchTrainingEvent objects and epoch events as a list of EpochTrainingEvent objects.

NOTE: Used to record BatchTrainingEvent and EpochTrainingEvent during training phase.

Constructors

TrainingHistory
Link copied to clipboard
fun TrainingHistory()

Functions

appendBatch
Link copied to clipboard
fun appendBatch(batchTrainingEvent: BatchTrainingEvent)

Appends one BatchTrainingEvent.

fun appendBatch(epochIndex: Int, batchIndex: Int, lossValue: Double, metricValue: Double)

Appends tracked data from one batch event.

appendEpoch
Link copied to clipboard
fun appendEpoch(epochTrainingEvent: EpochTrainingEvent)

Appends one EpochTrainingEvent.

fun appendEpoch(epochIndex: Int, lossValue: Double, metricValue: Double, valLossValue: Double?, valMetricValue: Double?)

Appends tracked data from one epoch event.

eventsByEpoch
Link copied to clipboard
fun eventsByEpoch(epochIndex: Int): TreeMap<Int, BatchTrainingEvent>?

Returns all BatchTrainingEvent of the specific epoch.

get
Link copied to clipboard
operator fun get(desiredField: KProperty1<EpochTrainingEvent, Double>): DoubleArray

Returns all values of one filed in EpochTrainingEvent for all epochs. All EpochTrainingEvent.metricValue for example.

lastBatchEvent
Link copied to clipboard
fun lastBatchEvent(): BatchTrainingEvent

Returns last BatchTrainingEvent

lastEpochEvent
Link copied to clipboard
fun lastEpochEvent(): EpochTrainingEvent

Returns last EpochTrainingEvent.

Properties

batchHistory
Link copied to clipboard
val batchHistory: List<BatchTrainingEvent>

Batch history.

epochHistory
Link copied to clipboard
val epochHistory: List<EpochTrainingEvent>

Epoch history.