Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CheckPoint ¶
CheckPoint is the model checkpoint in the form of weights and biases.
type Data ¶
Data is a data to be fed to the trainer in the form of a 2D matrix and associated labels. Data.Data has observations, one per row (first index) and features as columns. Y has classes probabilities as columns. Class with max probability is compared against prediction.
type Operator ¶
type Operator interface { // Step through iterations of training process. Step(trainingData, validationData *Data) (*TrainingOutput, error) // Predict the model outcome. Predict(data *Data) (*PredictionOutput, error) // Save obtains model checkpoint. Save() (*CheckPoint, error) // Load re-initializes trainer with a checkpoint. Load(checkPoint *CheckPoint) error }
Operator defines methods to train, predict and checkpoint a model
type PredictionOutput ¶
PredictionOutput is the output from prediction.
type TrainingOutput ¶
type TrainingOutput struct { CrossEntropy float32 TrainingAccuracy float32 ValidationAccuracy float32 }
TrainingOutput is the output from each training step.
Click to show internal directories.
Click to hide internal directories.