public class ModelsComposition extends Object implements IgniteModel<Vector,Double>, Exportable<ModelsCompositionFormat>, DeployableObject
Constructor and Description |
---|
ModelsComposition(List<? extends IgniteModel<Vector,Double>> models,
PredictionsAggregator predictionsAggregator)
Constructs a new instance of composition of models.
|
Modifier and Type | Method and Description |
---|---|
List<Object> |
getDependencies()
Returns dependencies of this object that can be object with class defined by client side and unknown for server.
|
List<IgniteModel<Vector,Double>> |
getModels()
Returns containing models.
|
PredictionsAggregator |
getPredictionsAggregator()
Returns predictions aggregator.
|
Double |
predict(Vector features)
Applies containing models to features and aggregate them to one prediction.
|
<P> void |
saveModel(Exporter<ModelsCompositionFormat,P> exporter,
P path)
Save model by the given path.
|
String |
toString() |
String |
toString(boolean pretty) |
public ModelsComposition(List<? extends IgniteModel<Vector,Double>> models, PredictionsAggregator predictionsAggregator)
models
- Basic models.predictionsAggregator
- Predictions aggregator.public Double predict(Vector features)
public PredictionsAggregator getPredictionsAggregator()
public List<IgniteModel<Vector,Double>> getModels()
public <P> void saveModel(Exporter<ModelsCompositionFormat,P> exporter, P path)
saveModel
in interface Exportable<ModelsCompositionFormat>
exporter
- Exporter.path
- Path to saved model.public String toString(boolean pretty)
toString
in interface IgniteModel<Vector,Double>
pretty
- Use pretty mode.public List<Object> getDependencies()
getDependencies
in interface DeployableObject
GridGain In-Memory Computing Platform : ver. 8.9.14 Release Date : November 5 2024