📄 multilayerperceptron.html
字号:
</DD><DD><DL><DT><B>Returns:</B><DD>The flag for nominal to binary filter use.</DL></DD></DL><HR><A NAME="setRandomSeed(long)"><!-- --></A><H3>setRandomSeed</H3><PRE>public void <B>setRandomSeed</B>(long l)</PRE><DL><DD>This seeds the random number generator, that is used when a random number is needed for the network.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>l</CODE> - The seed.</DL></DD></DL><HR><A NAME="getRandomSeed()"><!-- --></A><H3>getRandomSeed</H3><PRE>public long <B>getRandomSeed</B>()</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The seed for the random number generator.</DL></DD></DL><HR><A NAME="setValidationThreshold(int)"><!-- --></A><H3>setValidationThreshold</H3><PRE>public void <B>setValidationThreshold</B>(int t)</PRE><DL><DD>This sets the threshold to use for when validation testing is being done. It works by ending testing once the error on the validation set has consecutively increased a certain number of times.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>t</CODE> - The threshold to use for this.</DL></DD></DL><HR><A NAME="getValidationThreshold()"><!-- --></A><H3>getValidationThreshold</H3><PRE>public int <B>getValidationThreshold</B>()</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The threshold used for validation testing.</DL></DD></DL><HR><A NAME="setLearningRate(double)"><!-- --></A><H3>setLearningRate</H3><PRE>public void <B>setLearningRate</B>(double l)</PRE><DL><DD>The learning rate can be set using this command. NOTE That this is a static variable so it affect all networks that are running. Must be greater than 0 and no more than 1.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>l</CODE> - The New learning rate.</DL></DD></DL><HR><A NAME="getLearningRate()"><!-- --></A><H3>getLearningRate</H3><PRE>public double <B>getLearningRate</B>()</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The learning rate for the nodes.</DL></DD></DL><HR><A NAME="setMomentum(double)"><!-- --></A><H3>setMomentum</H3><PRE>public void <B>setMomentum</B>(double m)</PRE><DL><DD>The momentum can be set using this command. THE same conditions apply to this as to the learning rate.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>m</CODE> - The new Momentum.</DL></DD></DL><HR><A NAME="getMomentum()"><!-- --></A><H3>getMomentum</H3><PRE>public double <B>getMomentum</B>()</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The momentum for the nodes.</DL></DD></DL><HR><A NAME="setAutoBuild(boolean)"><!-- --></A><H3>setAutoBuild</H3><PRE>public void <B>setAutoBuild</B>(boolean a)</PRE><DL><DD>This will set whether the network is automatically built or if it is left up to the user. (there is nothing to stop a user from altering an autobuilt network however).<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>a</CODE> - True if the network should be auto built.</DL></DD></DL><HR><A NAME="getAutoBuild()"><!-- --></A><H3>getAutoBuild</H3><PRE>public boolean <B>getAutoBuild</B>()</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The auto build state.</DL></DD></DL><HR><A NAME="setHiddenLayers(java.lang.String)"><!-- --></A><H3>setHiddenLayers</H3><PRE>public void <B>setHiddenLayers</B>(java.lang.String h)</PRE><DL><DD>This will set what the hidden layers are made up of when auto build is enabled. Note to have no hidden units, just put a single 0, Any more 0's will indicate that the string is badly formed and make it unaccepted. Negative numbers, and floats will do the same. There are also some wildcards. These are 'a' = (number of attributes + number of classes) / 2, 'i' = number of attributes, 'o' = number of classes, and 't' = number of attributes + number of classes.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>h</CODE> - A string with a comma seperated list of numbers. Each number is the number of nodes to be on a hidden layer.</DL></DD></DL><HR><A NAME="getHiddenLayers()"><!-- --></A><H3>getHiddenLayers</H3><PRE>public java.lang.String <B>getHiddenLayers</B>()</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>A string representing the hidden layers, each number is the number of nodes on a hidden layer.</DL></DD></DL><HR><A NAME="setGUI(boolean)"><!-- --></A><H3>setGUI</H3><PRE>public void <B>setGUI</B>(boolean a)</PRE><DL><DD>This will set whether A GUI is brought up to allow interaction by the user with the neural network during training.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>a</CODE> - True if gui should be created.</DL></DD></DL><HR><A NAME="getGUI()"><!-- --></A><H3>getGUI</H3><PRE>public boolean <B>getGUI</B>()</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The true if should show gui.</DL></DD></DL><HR><A NAME="setValidationSetSize(int)"><!-- --></A><H3>setValidationSetSize</H3><PRE>public void <B>setValidationSetSize</B>(int a)</PRE><DL><DD>This will set the size of the validation set.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>a</CODE> - The size of the validation set, as a percentage of the whole.</DL></DD></DL><HR><A NAME="getValidationSetSize()"><!-- --></A><H3>getValidationSetSize</H3><PRE>public int <B>getValidationSetSize</B>()</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The percentage size of the validation set.</DL></DD></DL><HR><A NAME="setTrainingTime(int)"><!-- --></A><H3>setTrainingTime</H3><PRE>public void <B>setTrainingTime</B>(int n)</PRE><DL><DD>Set the number of training epochs to perform. Must be greater than 0.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>n</CODE> - The number of epochs to train through.</DL></DD></DL><HR><A NAME="getTrainingTime()"><!-- --></A><H3>getTrainingTime</H3><PRE>public int <B>getTrainingTime</B>()</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The number of epochs to train through.</DL></DD></DL><HR><A NAME="blocker(boolean)"><!-- --></A><H3>blocker</H3><PRE>public void <B>blocker</B>(boolean tf)</PRE><DL><DD>A function used to stop the code that called buildclassifier from continuing on before the user has finished the decision tree.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>tf</CODE> - True to stop the thread, False to release the thread that is waiting there (if one).</DL></DD></DL><HR><A NAME="buildClassifier(weka.core.Instances)"><!-- --></A><H3>buildClassifier</H3><PRE>public void <B>buildClassifier</B>(<A HREF="../../../weka/core/Instances.html" title="class in weka.core">Instances</A> i) throws java.lang.Exception</PRE><DL><DD>Call this function to build and train a neural network for the training data provided.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../weka/classifiers/Classifier.html#buildClassifier(weka.core.Instances)">buildClassifier</A></CODE> in class <CODE><A HREF="../../../weka/classifiers/Classifier.html" title="class in weka.classifiers">Classifier</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>i</CODE> - The training data.<DT><B>Throws:</B><DD><CODE>Throws</CODE> - exception if can't build classification properly.<DD><CODE>java.lang.Exception</CODE> - if the classifier has not been generated successfully</DL></DD></DL><HR><A NAME="distributionForInstance(weka.core.Instance)"><!-- --></A><H3>distributionForInstance</H3><PRE>public double[] <B>distributionForInstance</B>(<A HREF="../../../weka/core/Instance.html" title="class in weka.core">Instance</A> i) throws java.lang.Exception</PRE><DL><DD>Call this function to predict the class of an instance once a classification model has been built with the buildClassifier call.<P><DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../../../weka/classifiers/Classifier.html#distributionForInstance(weka.core.Instance)">distributionForInstance</A></CODE> in class <CODE><A HREF="../../../weka/classifiers/Classifier.html" title="class in weka.classifiers">Classifier</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>i</CODE> - The instance to classify.<DT><B>Returns:</B><DD>A double array filled with the probabilities of each class type.<DT><B>Throws:</B><DD><CODE>if</CODE> - can't classify instance.<DD><CODE>java.lang.Exception</CODE> - if distribution could not be computed successfully</DL></DD></DL><HR><A NAME="listOptions()"><!-- --></A><H3>listOptions</H3><PRE>public java.util.Enumeration <B>listOptions</B>()</PRE><DL><DD>Returns an enumeration describing the available options.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../weka/core/OptionHandler.html#listOptions()">listOptions</A></CODE> in interface <CODE><A HREF="../../../weka/core/OptionHandler.html" title="interface in weka.core">OptionHandler</A></CODE><DT><B>Overrides:</B><DD><CODE><A HREF="../../../weka/classifiers/Classifier.html#listOptions()">listOptions</A></CODE> in class <CODE><A HREF="../../../weka/classifiers/Classifier.html" title="class in weka.classifiers">Classifier</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>an enumeration of all the available options.</DL></DD></DL><HR><A NAME="setOptions(java.lang.String[])"><!-- --></A><H3>setOptions</H3><PRE>public void <B>setOptions</B>(java.lang.String[] options) throws java.lang.Exception</PRE>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -