DataPredict

API Reference - Models - BaseModel

The base model for all machine and deep learning models.

Constructors

new()

Creates a new machine learning base model.

BaseModel.new(): BaseModelObject

Functions

setModelParametersInitializationMode()

Sets how the initial model parameters values are generated. The model parameters will be generated when train() function is run.

BaseModel:setModelParametersInitializationMode(initializationMode: string, minimumModelParametersInitializationValue: number, maximumModelParametersInitializationValue: number)

Parameters:

getModelParameters()

Gets the model parameters from the base model.

BaseModel:getModelParameters(doNotDeepCopy: boolean): ModelParameters

Parameters

Returns

setModelParameters()

Set the model parameters to the base model.

BaseModel:setModelParameters(ModelParameters: ModelParameters, doNotDeepCopy: boolean)

Parameters

clearModelParameters()

Clears the model parameters contained inside base model.

BaseModel:clearModelParameters()

setNumberOfIterationsPerCostCalculation()

Set the number of iterations needed to calculate the costs. This is to save computational time.

BaseModel:setModelParameters(numberOfIterationsPerCostCalculation: number)

Parameters

setNumberOfIterationsToCheckIfConverged()

Set the number of iterations needed to confirm convergence.

BaseModel:setNumberOfIterationsToCheckIfConverged(numberOfIterations: number)

Parameters

setTargetCost()

Set the upper bound and lower bounds of the target cost.

BaseModel:setTargetCost(upperBound: number, lowerBound: number)

Parameters

setPrintOutput()

Set if the model prints output.

BaseModel:setPrintOutput(option: boolean)

Parameters:

setWaitDurations()

Set wait durations inside the models to avoid exhausting script running time.

BaseModel:setWaitDurations(iterationWaitDuration: number, dataWaitDuration: number, sequenceWaitDuration: number)

Parameters: