📄 ensembleselectionlibrary.html
字号:
<TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../weka/classifiers/meta/ensembleSelection/EnsembleSelectionLibrary.html#removeModel(java.lang.String)">removeModel</A></B>(java.lang.String modelKey)</CODE><BR> This will remove the model associated with the given String from the model libraryHashMap</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../weka/classifiers/meta/ensembleSelection/EnsembleSelectionLibrary.html#setDebug(boolean)">setDebug</A></B>(boolean debug)</CODE><BR> Set debug flag for the library and all its models.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../weka/classifiers/meta/ensembleSelection/EnsembleSelectionLibrary.html#setModelListFile(java.lang.String)">setModelListFile</A></B>(java.lang.String modelListFile)</CODE><BR> Sets the model list file that holds the list of models in the ensemble library.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../weka/classifiers/meta/ensembleSelection/EnsembleSelectionLibrary.html#setNumFolds(int)">setNumFolds</A></B>(int numFolds)</CODE><BR> Set the number of folds for cross validation.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../weka/classifiers/meta/ensembleSelection/EnsembleSelectionLibrary.html#setValidationRatio(double)">setValidationRatio</A></B>(double validationRatio)</CODE><BR> Sets the validation-set ratio.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../weka/classifiers/meta/ensembleSelection/EnsembleSelectionLibrary.html#setWorkingDirectory(java.io.File)">setWorkingDirectory</A></B>(java.io.File workingDirectory)</CODE><BR> Sets the working Directory of the ensemble library.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../../../weka/core/Instances.html" title="class in weka.core">Instances</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../../weka/classifiers/meta/ensembleSelection/EnsembleSelectionLibrary.html#trainAll(weka.core.Instances, java.lang.String, int)">trainAll</A></B>(<A HREF="../../../../weka/core/Instances.html" title="class in weka.core">Instances</A> data, java.lang.String directory, int algorithm)</CODE><BR> This method will iterate through the TreeMap of models and train all models that do not currently exist (are not yet trained).</TD></TR></TABLE> <A NAME="methods_inherited_from_class_weka.classifiers.EnsembleLibrary"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TH ALIGN="left"><B>Methods inherited from class weka.classifiers.<A HREF="../../../../weka/classifiers/EnsembleLibrary.html" title="class in weka.classifiers">EnsembleLibrary</A></B></TH></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="../../../../weka/classifiers/EnsembleLibrary.html#addModel(weka.classifiers.EnsembleLibraryModel)">addModel</A>, <A HREF="../../../../weka/classifiers/EnsembleLibrary.html#addModel(java.lang.String)">addModel</A>, <A HREF="../../../../weka/classifiers/EnsembleLibrary.html#addPropertyChangeListener(java.beans.PropertyChangeListener)">addPropertyChangeListener</A>, <A HREF="../../../../weka/classifiers/EnsembleLibrary.html#clearModels()">clearModels</A>, <A HREF="../../../../weka/classifiers/EnsembleLibrary.html#getModels()">getModels</A>, <A HREF="../../../../weka/classifiers/EnsembleLibrary.html#loadLibrary(java.io.File, weka.classifiers.EnsembleLibrary)">loadLibrary</A>, <A HREF="../../../../weka/classifiers/EnsembleLibrary.html#loadLibrary(java.io.File, javax.swing.JComponent, weka.classifiers.EnsembleLibrary)">loadLibrary</A>, <A HREF="../../../../weka/classifiers/EnsembleLibrary.html#loadLibrary(java.io.InputStream, weka.classifiers.EnsembleLibrary)">loadLibrary</A>, <A HREF="../../../../weka/classifiers/EnsembleLibrary.html#removeModel(weka.classifiers.EnsembleLibraryModel)">removeModel</A>, <A HREF="../../../../weka/classifiers/EnsembleLibrary.html#saveLibrary(java.io.File, weka.classifiers.EnsembleLibrary, javax.swing.JComponent)">saveLibrary</A>, <A HREF="../../../../weka/classifiers/EnsembleLibrary.html#setModels(java.util.TreeSet)">setModels</A>, <A HREF="../../../../weka/classifiers/EnsembleLibrary.html#size()">size</A></CODE></TD></TR></TABLE> <A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TH ALIGN="left"><B>Methods inherited from class java.lang.Object</B></TH></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE>equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD></TR></TABLE> <P><!-- ============ FIELD DETAIL =========== --><A NAME="field_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2"><B>Field Detail</B></FONT></TH></TR></TABLE><A NAME="m_Debug"><!-- --></A><H3>m_Debug</H3><PRE>public transient boolean <B>m_Debug</B></PRE><DL><DD>Whether we should print debug messages.<P><DL></DL></DL><!-- ========= CONSTRUCTOR DETAIL ======== --><A NAME="constructor_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2"><B>Constructor Detail</B></FONT></TH></TR></TABLE><A NAME="EnsembleSelectionLibrary()"><!-- --></A><H3>EnsembleSelectionLibrary</H3><PRE>public <B>EnsembleSelectionLibrary</B>()</PRE><DL><DD>Creates a default libary. Library should be associated with<P></DL><HR><A NAME="EnsembleSelectionLibrary(java.lang.String, int, int, double)"><!-- --></A><H3>EnsembleSelectionLibrary</H3><PRE>public <B>EnsembleSelectionLibrary</B>(java.lang.String dir, int seed, int folds, double validationRatio)</PRE><DL><DD>Creates a default libary. Library should be associated with a working directory<P><DL><DT><B>Parameters:</B><DD><CODE>dir</CODE> - the working directory form the ensemble library<DD><CODE>seed</CODE> - the seed value<DD><CODE>folds</CODE> - the number of folds<DD><CODE>validationRatio</CODE> - the ratio to use</DL></DL><HR><A NAME="EnsembleSelectionLibrary(java.lang.String)"><!-- --></A><H3>EnsembleSelectionLibrary</H3><PRE>public <B>EnsembleSelectionLibrary</B>(java.lang.String libraryFileName)</PRE><DL><DD>This constructor will create a library from a model list file given by the file name argument<P><DL><DT><B>Parameters:</B><DD><CODE>libraryFileName</CODE> - the library filename</DL></DL><HR><A NAME="EnsembleSelectionLibrary(java.io.InputStream)"><!-- --></A><H3>EnsembleSelectionLibrary</H3><PRE>public <B>EnsembleSelectionLibrary</B>(java.io.InputStream stream)</PRE><DL><DD>This constructor will create a library from the given XML stream.<P><DL><DT><B>Parameters:</B><DD><CODE>stream</CODE> - the XML library stream</DL></DL><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2"><B>Method Detail</B></FONT></TH></TR></TABLE><A NAME="setDebug(boolean)"><!-- --></A><H3>setDebug</H3><PRE>public void <B>setDebug</B>(boolean debug)</PRE><DL><DD>Set debug flag for the library and all its models. The debug flag determines whether we print debugging information to stdout.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>debug</CODE> - if true debug mode is on</DL></DD></DL><HR><A NAME="setValidationRatio(double)"><!-- --></A><H3>setValidationRatio</H3><PRE>public void <B>setValidationRatio</B>(double validationRatio)</PRE><DL><DD>Sets the validation-set ratio. This is the portion of the training set that is set aside for hillclimbing. Note that this value is ignored if we are doing cross-validation (indicated by the number of folds being > 1).<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>validationRatio</CODE> - the new ratio</DL></DD></DL><HR><A NAME="setNumFolds(int)"><!-- --></A><H3>setNumFolds</H3><PRE>public void <B>setNumFolds</B>(int numFolds)</PRE><DL><DD>Set the number of folds for cross validation. If the number of folds is > 1, the validation ratio is ignored.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>numFolds</CODE> - the number of folds to use</DL></DD></DL><HR><A NAME="trainAll(weka.core.Instances, java.lang.String, int)"><!-- --></A><H3>trainAll</H3><PRE>public <A HREF="../../../../weka/core/Instances.html" title="class in weka.core">Instances</A> <B>trainAll</B>(<A HREF="../../../../weka/core/Instances.html" title="class in weka.core">Instances</A> data, java.lang.String directory, int algorithm) throws java.lang.Exception</PRE><DL><DD>This method will iterate through the TreeMap of models and train all models that do not currently exist (are not yet trained). <p/> Returns the data set which should be used for hillclimbing. <p/> If training a model fails then an error will be sent to stdout and that model will be removed from the TreeMap. FIXME Should we maybe raise an exception instead?<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>data</CODE> - the data to work on<DD><CODE>directory</CODE> - the working directory<DD><CODE>algorithm</CODE> - the type of algorithm<DT><B>Returns:</B><DD>the data that should be used for hillclimbing<DT><B>Throws:</B><DD><CODE>java.lang.Exception</CODE> - if something goes wrong</DL></DD></DL><HR><A NAME="createWorkingDirectory(java.lang.String)"><!-- --></A><H3>createWorkingDirectory</H3><PRE>public void <B>createWorkingDirectory</B>(java.lang.String dirName)</PRE><DL><DD>Creates the working directory associated with this library<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>dirName</CODE> - the new directory</DL></DD></DL><HR><A NAME="removeModel(java.lang.String)"><!-- --></A><H3>removeModel</H3><PRE>public void <B>removeModel</B>(java.lang.String modelKey)</PRE><DL><DD>This will remove the model associated with the given String from the model libraryHashMap<P>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -