Class TTinyNN
Unit
pastinn
Declaration
type TTinyNN = class(TObject)
Description
Tiny neural network main class
Hierarchy
Overview
Methods
Description
Methods
|
function err(const a: Single; const b: Single): Single; |
Calculates error
|
|
function pderr(const a: Single; const b: Single): Single; |
Calculates partial derivative of error function
|
|
function toterr(index: Integer): Single; |
Calculates total error of output target
|
|
function act(const a: Single): Single; |
Activation function
|
|
function pdact(const a: Single): Single; |
Returns partial derivative of activation function
|
|
procedure bprop(const rate: Single); |
Performs back propagation
|
|
procedure fprop; |
Performs forward propagation
|
|
procedure wbrand; |
Randomize weights and baises
|
|
function Train(const rate: Single; index: Integer): Single; |
Trains a tinn with an input and target output with a learning rate. Returns target to output error
|
|
procedure Build(nips: Integer; nhid: Integer; nops: Integer); |
Prepare the TPasTinn record for usage
|
|
function Predict(index: Integer): TSingleArray; |
Returns an output prediction on given input
|
|
procedure SaveToFile(path: String); |
Save neural network to file
|
|
procedure LoadFromFile(path: String); |
Load neural network from file
|
|
procedure PrintToScreen(arr: TSingleArray; size: Integer); |
Dump contents of array to screen
|
|
procedure SetData(inp: TTinnData); |
Set input data
|
|
procedure ShuffleData; |
Shuffle input data
|
Generated by PasDoc 0.15.0.
|