|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.knime.core.node.NodeModel
org.knime.base.node.mine.bfn.BasisFunctionPredictorNodeModel
public abstract class BasisFunctionPredictorNodeModel
The basis function predictor model performing a prediction on the data from the first input and the radial basisfunction model from the second.
BasisFunctionPredictorCellFactory
Constructor Summary | |
---|---|
protected |
BasisFunctionPredictorNodeModel(PortType model)
Creates a new basisfunction predictor model with two inputs, the first one which contains the data and the second with the model. |
Method Summary | |
---|---|
boolean |
appendClassProbabilities()
|
DataTableSpec[] |
configure(PortObjectSpec[] portObjSpec)
Configure method for general port types. |
ColumnRearranger |
createRearranger(DataTableSpec dataSpec,
String[] modelSpec)
Creates a column rearranger based on the data spec. |
DataColumnSpec[] |
createSpec(DataTableSpec dataSpec,
DataTableSpec modelSpec,
int modelClassIdx)
Creates the output model spec. |
BufferedDataTable[] |
execute(PortObject[] portObj,
ExecutionContext exec)
Execute method for general port types. |
String |
getApplyColumn()
|
double |
getDontKnowClassDegree()
|
void |
loadInternals(File internDir,
ExecutionMonitor exec)
Load internals into the derived NodeModel . |
void |
loadValidatedSettingsFrom(NodeSettingsRO settings)
Sets new settings from the passed object in the model. |
abstract boolean |
normalizeClassification()
|
void |
reset()
Override this function in the derived model and reset your NodeModel . |
void |
saveInternals(File internDir,
ExecutionMonitor exec)
Save internals of the derived NodeModel . |
void |
saveSettingsTo(NodeSettingsWO settings)
Adds to the given NodeSettings the model specific
settings. |
void |
validateSettings(NodeSettingsRO settings)
Validates the settings in the passed NodeSettings object. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected BasisFunctionPredictorNodeModel(PortType model)
model
- type of the basisfunction model at the in-portMethod Detail |
---|
public BufferedDataTable[] execute(PortObject[] portObj, ExecutionContext exec) throws CanceledExecutionException, InvalidSettingsException
PortObject classes
that are defined through the
PortTypes
given in the
constructor
.
Similarly, the returned output objects need to comply with their port
types object class (otherwise an error is reported by the framework).
For a general description of the execute method refer to the description
of the specialized
NodeModel.execute(BufferedDataTable[], ExecutionContext)
methods as it
addresses more use cases.
execute
in class NodeModel
portObj
- The input objects.exec
- For BufferedDataTable
creation and progress.
CanceledExecutionException
InvalidSettingsException
public final DataColumnSpec[] createSpec(DataTableSpec dataSpec, DataTableSpec modelSpec, int modelClassIdx)
dataSpec
- input data specmodelSpec
- input model specmodelClassIdx
- index with reflects the class column
public abstract boolean normalizeClassification()
true
if normalization is required for outputpublic String getApplyColumn()
public double getDontKnowClassDegree()
public boolean appendClassProbabilities()
public DataTableSpec[] configure(PortObjectSpec[] portObjSpec) throws InvalidSettingsException
PortObjectSpecs
that are defined through the
PortTypes
given in the
constructor
.
Similarly, the returned output specs need to comply with their port types
spec class (otherwise an error is reported by the framework). They may
also be null.
For a general description of the configure method refer to the
description of the specialized NodeModel.configure(DataTableSpec[])
methods as it addresses more use cases.
configure
in class NodeModel
portObjSpec
- The input object specs.
InvalidSettingsException
- If this node can't be configured.public final ColumnRearranger createRearranger(DataTableSpec dataSpec, String[] modelSpec) throws InvalidSettingsException
dataSpec
- data specmodelSpec
- model spec
InvalidSettingsException
- if the settings are not valid against
data and/or model specpublic void reset()
NodeModel
. All components should unregister themselves
from any observables (at least from the hilite handler right now). All
internally stored data structures should be released. User settings
should not be deleted/reset though.
reset
in class NodeModel
public void loadValidatedSettingsFrom(NodeSettingsRO settings) throws InvalidSettingsException
#validateSettings(NodeSettings)
method. The model must set
its internal configuration according to the settings object passed.
loadValidatedSettingsFrom
in class NodeModel
settings
- The settings to read.
InvalidSettingsException
- If a property is not available.NodeModel.saveSettingsTo(NodeSettingsWO)
,
NodeModel.validateSettings(NodeSettingsRO)
public void saveSettingsTo(NodeSettingsWO settings)
NodeSettings
the model specific
settings. The settings don't need to be complete or consistent. If, right
after startup, no valid settings are available this method can write
either nothing or invalid settings.
Method is called by the Node
if the current settings need
to be saved or transfered to the node's dialog.
saveSettingsTo
in class NodeModel
settings
- The object to write settings into.NodeModel.loadValidatedSettingsFrom(NodeSettingsRO)
,
NodeModel.validateSettings(NodeSettingsRO)
public void validateSettings(NodeSettingsRO settings) throws InvalidSettingsException
NodeSettings
object.
The specified settings should be checked for completeness and
consistency. It must be possible to load a settings object validated
here without any exception in the
#loadValidatedSettings(NodeSettings)
method. The method
must not change the current settings in the model - it is supposed to
just check them. If some settings are missing, invalid, inconsistent, or
just not right throw an exception with a message useful to the user.
validateSettings
in class NodeModel
settings
- The settings to validate.
InvalidSettingsException
- If the validation of the settings
failed.NodeModel.saveSettingsTo(NodeSettingsWO)
,
NodeModel.loadValidatedSettingsFrom(NodeSettingsRO)
public void loadInternals(File internDir, ExecutionMonitor exec)
NodeModel
. This method is
only called if the Node
was executed. Read all your
internal structures from the given file directory to create your internal
data structure which is necessary to provide all node functionalities
after the workflow is loaded, e.g. view content and/or hilite mapping.
loadInternals
in class NodeModel
internDir
- The directory to read from.exec
- Used to report progress and to cancel the load process.NodeModel.saveInternals(File,ExecutionMonitor)
public void saveInternals(File internDir, ExecutionMonitor exec)
NodeModel
. This method is
only called if the Node
is executed. Write all your
internal structures into the given file directory which are necessary to
recreate this model when the workflow is loaded, e.g. view content and/or
hilite mapping.
saveInternals
in class NodeModel
internDir
- The directory to write into.exec
- Used to report progress and to cancel the save process.NodeModel.loadInternals(File,ExecutionMonitor)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |