com.rapidminer.operator.meta
Class GridSearchParameterOptimizationOperator
java.lang.Object
com.rapidminer.operator.Operator
com.rapidminer.operator.OperatorChain
com.rapidminer.operator.meta.ParameterIteratingOperatorChain
com.rapidminer.operator.meta.ParameterOptimizationOperator
com.rapidminer.operator.meta.GridSearchParameterOptimizationOperator
- All Implemented Interfaces:
- ConfigurationListener, PreviewListener, ParameterHandler, LoggingHandler
- Direct Known Subclasses:
- QuadraticParameterOptimizationOperator
public class GridSearchParameterOptimizationOperator
- extends ParameterOptimizationOperator
This operator finds the optimal values for a set of parameters using a grid
search. The parameter parameters is a list of key value pairs
where the keys are of the form operator_name.parameter_name and
the value is either a comma separated list of values (e.g. 10,15,20,25) or an
interval definition in the format [start;end;stepsize] (e.g. [10;25;5]).
Alternatively a value grid pattern may be used by [e.g. [start;end;no_steps;scale],
where scale identifies the type of the pattern.
The operator returns an
optimal ParameterSet which can as well be written to a file with a
ParameterSetWriter. This parameter set
can be read in another process using a
ParameterSetLoader.
The file format of the parameter set file is straightforward and can easily be
generated by external applications. Each line is of the form
operator_name.parameter_name = value
Please refer to section
Advanced Processes/Parameter and performance analysis
for an example application. Another parameter optimization schems like the
EvolutionaryParameterOptimizationOperator might also be useful if the best ranges
and dependencies are not known at all. Another operator which works similar to this parameter
optimization operator is the operator ParameterIteration. In contrast to the optimization
operator, this operator simply iterates through all parameter combinations. This might be
especially useful for plotting purposes.
- Author:
- Simon Fischer, Helge Homburg, Ingo Mierswa, Tobias Malbrecht
15:35:49 ingomierswa Exp $
| Methods inherited from class com.rapidminer.operator.OperatorChain |
addAddListener, addOperator, addOperator, checkDeprecations, checkIO, checkNumberOfInnerOperators, checkProperties, clearErrorList, cloneOperator, createExperimentTree, createProcessTree, getAllInnerOperators, getIndexOfOperator, getInnerOperatorForName, getInnerOperatorsXML, getNumberOfAllOperators, getNumberOfOperators, getOperator, getOperatorFromAll, getOperators, performAdditionalChecks, processFinished, processStarts, registerOperator, removeAddListener, removeOperator, shouldReturnInnerOutput, unregisterOperator |
| Methods inherited from class com.rapidminer.operator.Operator |
addError, addValue, addWarning, apply, checkForStop, createExperimentTree, createFromXML, createMarkedExperimentTree, createMarkedProcessTree, createProcessTree, getAddOnlyAdditionalOutput, getApplyCount, getDeliveredOutputClasses, getDeprecationInfo, getDesiredInputClasses, getEncoding, getErrorList, getExperiment, getInput, getInput, getInput, getInputDescription, getIOContainerForInApplyLoopBreakpoint, getIODescription, getLog, getName, getOperatorClassName, getOperatorDescription, getParameter, getParameterAsBoolean, getParameterAsColor, getParameterAsDouble, getParameterAsFile, getParameterAsFile, getParameterAsInputStream, getParameterAsInt, getParameterAsMatrix, getParameterAsString, getParameterList, getParameters, getParameterType, getParent, getProcess, getStartTime, getStatus, getUserDescription, getValue, getValues, getXML, hasBreakpoint, hasBreakpoint, hasInput, inApplyLoop, isDebugMode, isEnabled, isExpanded, isParallel, isParameterSet, log, logError, logNote, logWarning, register, remove, rename, resume, setApplyCount, setBreakpoint, setEnabled, setExpanded, setInput, setListParameter, setOperatorParameters, setParameter, setParameters, setParent, setUserDescription, toString, writeXML |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
operators
protected Operator[] operators
parameters
protected java.lang.String[] parameters
values
protected java.lang.String[][] values
currentIndex
protected int[] currentIndex
numberOfCombinations
protected int numberOfCombinations
numberOfParameters
protected int numberOfParameters
GridSearchParameterOptimizationOperator
public GridSearchParameterOptimizationOperator(OperatorDescription description)
getParameterValueMode
public int getParameterValueMode()
- Description copied from class:
ParameterIteratingOperatorChain
- Has to return one of the predefined modes which indicate whether the
operator takes discrete values or intervals as basis for optimization.
The first option is to be taken for all strategies that iterate over the
given parameters. The latter option is to be taken for strategies such
as an evolutionary one in which allowed ranges of parameters have to be
specified.
- Specified by:
getParameterValueMode in class ParameterIteratingOperatorChain
getParametersToOptimize
protected void getParametersToOptimize()
throws OperatorException
- Throws:
OperatorException
getCurrentBestPerformance
public double getCurrentBestPerformance()
- Specified by:
getCurrentBestPerformance in class ParameterOptimizationOperator
apply
public IOObject[] apply()
throws OperatorException
- Description copied from class:
OperatorChain
- Applies all inner operators. The input to this operator becomes the input
of the first inner operator. The latter's output is passed to the second
inner operator and so on. Note to subclassers: If subclasses (for example
wrappers) want to make use of this method remember to call exactly this
method (super.apply()) and do not call
super.apply(IOContainer) erroneously which will result in an
infinite loop.
- Overrides:
apply in class OperatorChain
- Returns:
- the last inner operator's output or the input itself if the chain
is empty.
- Throws:
OperatorException
Copyright © 2001-2009 by Rapid-I