Interface IStratiAssigner
-
- All Superinterfaces:
org.api4.java.common.control.IParallelizable
- All Known Implementing Classes:
AttributeBasedStratiAmountSelectorAndAssigner,ClusterStratiAssigner,GMeansStratiAmountSelectorAndAssigner,KMeansStratiAssigner
public interface IStratiAssigner extends org.api4.java.common.control.IParallelizableInterface to write custom Assigner for datapoints to strati.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intassignToStrati(org.api4.java.ai.ml.core.dataset.IInstance datapoint)Custom logic for assigning datapoints into strati.voidinit(org.api4.java.ai.ml.core.dataset.IDataset<?> dataset, int stratiAmount)Initialize custom assigner if necessary.
-
-
-
Method Detail
-
init
void init(org.api4.java.ai.ml.core.dataset.IDataset<?> dataset, int stratiAmount)Initialize custom assigner if necessary.- Parameters:
dataset- The dataset the datapoints will be sampled from.stratiAmount- The predetermined amount of strati the dataset will be stratified into.
-
assignToStrati
int assignToStrati(org.api4.java.ai.ml.core.dataset.IInstance datapoint)
Custom logic for assigning datapoints into strati.- Parameters:
datapoint- The datapoint that has to be assigned.- Returns:
- The index of the strati the datapoint will be assigned into.
-
-