Home › Packages › neural-nets

Package neural-nets

This package contains 3 source unit(s) defining 3 class(es) / struct(s). Each unit below lists its fields (the values it stores) and methods (the actions it performs), with a plain explanation of each.

SLNeuralNetwork #sleela 3.0 (lib/neural-nets/SLNeuralNetwork.sleela)

SLNeuralNetwork class

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
STATUS_OKstatic final int STATUS_OK = 0No description in source.
STATUS_INVALID_ARGUMENTstatic final int STATUS_INVALID_ARGUMENT = 1No description in source.
STATUS_OUT_OF_MEMORYstatic final int STATUS_OUT_OF_MEMORY = 2No description in source.
STATUS_INVALID_STATEstatic final int STATUS_INVALID_STATE = 3No description in source.
STATUS_SIZE_MISMATCHstatic final int STATUS_SIZE_MISMATCH = 4No description in source.
STATUS_NUMERICstatic final int STATUS_NUMERIC = 5No description in source.
STATUS_NATIVE_ADAPTER_REQUIREDstatic final int STATUS_NATIVE_ADAPTER_REQUIRED = 6No description in source.
configuredboolean configured = falseNo description in source.
inputCountint inputCount = 0No description in source.
outputCountint outputCount = 0No description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
configureint configure(SLNeuralNetworkConfig config)No description in source.
isConfiguredboolean isConfigured()No description in source.
isNativeReadyboolean isNativeReady()No description in source.
getInputCountint getInputCount()No description in source.
getOutputCountint getOutputCount()No description in source.
predictint predict(double[] input, double[] output)No description in source.
trainSampleint trainSample(double[] input, double[] target, double learningRate)No description in source.
closevoid close()No description in source.

SLNeuralNetworkConfig #sleela 3.0 (lib/neural-nets/SLNeuralNetworkConfig.sleela)

SLNeuralNetworkConfig class

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
ACTIVATION_LINEARstatic final int ACTIVATION_LINEAR = 0No description in source.
ACTIVATION_RELUstatic final int ACTIVATION_RELU = 1No description in source.
ACTIVATION_TANHstatic final int ACTIVATION_TANH = 2No description in source.
ACTIVATION_SIGMOIDstatic final int ACTIVATION_SIGMOID = 3No description in source.
ABI_VERSIONstatic final int ABI_VERSION = 1No description in source.
layerSizesint[] layerSizesNo description in source.
hiddenActivationint hiddenActivation = ACTIVATION_RELUNo description in source.
outputActivationint outputActivation = ACTIVATION_LINEARNo description in source.
seedint seed = 0No description in source.
layerCountint layerCount = 0No description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
setLayerSizesvoid setLayerSizes(int[] sizes)No description in source.
getLayerSizesint[] getLayerSizes()No description in source.
getLayerCountint getLayerCount()No description in source.
setHiddenActivationvoid setHiddenActivation(int value)No description in source.
getHiddenActivationint getHiddenActivation()No description in source.
setOutputActivationvoid setOutputActivation(int value)No description in source.
getOutputActivationint getOutputActivation()No description in source.
setSeedvoid setSeed(int value)No description in source.
getSeedint getSeed()No description in source.
validboolean valid()No description in source.

SLPackage #sleela 3.0 (lib/neural-nets/SLPackage.sleela)

SLPackage class

Carries the standard Metadata Class record — eleven catalogued provenance attributes (version, id, author, date, copyright, trademark, corporation, origin, birth date, science rating, national schedule) with matching get/set accessors. These are omitted from the tables below for brevity.

Fields — the named values this unit stores.

FieldDeclarationWhat it holds
packageNameString packageName = "neural-nets"No description in source.
nativeHeaderString nativeHeader = "neural_nets.h"No description in source.
nativeAbiVersionint nativeAbiVersion = 1No description in source.
requiresNativeAdapterboolean requiresNativeAdapter = trueNo description in source.

Methods — the actions this unit can perform.

MethodSignatureWhat it does
nameString name()No description in source.
availableboolean available()No description in source.
isNativeAdapterRequiredboolean isNativeAdapterRequired()No description in source.