org.encog.util.normalize.input
Class InputFieldArray1D
- java.lang.Object
-
- org.encog.util.normalize.input.BasicInputField
-
- org.encog.util.normalize.input.InputFieldArray1D
-
- All Implemented Interfaces:
- java.io.Serializable, HasFixedLength, InputField
public class InputFieldArray1D extends BasicInputField implements HasFixedLength
An input field that comes from a 1D array. Note: this input field will not be persisted to an EG file. This is because it could point to a lengthy array, that really has no meaning inside of an EG file.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor and Description InputFieldArray1D(boolean usedForNetworkInput, double[] array)Construct the 1D array field.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description doublegetValue(int i)Get the value from the specified index.intlength()-
Methods inherited from class org.encog.util.normalize.input.BasicInputField
applyMinMax, getCurrentValue, getMax, getMin, getUsedForNetworkInput, setCurrentValue, setMax, setMin, setUsedForNetworkInput
-
-
-
-
Constructor Detail
-
InputFieldArray1D
public InputFieldArray1D(boolean usedForNetworkInput, double[] array)Construct the 1D array field.- Parameters:
usedForNetworkInput- True if this field is used for the actual input to the neural network. See getUsedForNetworkInput for more info.array- The array to use.
-
-
Method Detail
-
getValue
public double getValue(int i)
Get the value from the specified index.- Specified by:
getValuein interfaceInputField- Overrides:
getValuein classBasicInputField- Parameters:
i- The index to retrieve.- Returns:
- The value at the specified index.
-
length
public int length()
- Specified by:
lengthin interfaceHasFixedLength- Returns:
- The length of the array.
-
-
DMelt 3.0 © DataMelt by jWork.ORG