C
- Type of a partition context
.D
- Type of a partition data
.public class DatasetWrapper<C extends Serializable,D extends AutoCloseable> extends Object implements Dataset<C,D>
compute
methods.SimpleDataset
,
SimpleLabeledDataset
Modifier and Type | Field and Description |
---|---|
protected Dataset<C,D> |
delegate
Delegate that performs
compute actions. |
Constructor and Description |
---|
DatasetWrapper(Dataset<C,D> delegate)
Constructs a new instance of dataset wrapper that delegates
compute actions to the actual delegate. |
Modifier and Type | Method and Description |
---|---|
void |
close() |
<R> R |
compute(IgniteBiFunction<D,LearningEnvironment,R> map,
IgniteBinaryOperator<R> reduce,
R identity)
Applies the specified
map function to every partition data and LearningEnvironment
in the dataset and then reduces map results to final result by using the reduce function. |
<R> R |
computeWithCtx(IgniteTriFunction<C,D,LearningEnvironment,R> map,
IgniteBinaryOperator<R> reduce,
R identity)
Applies the specified
map function to every partition data , context and partition
index in the dataset and then reduces map results to final result by using the reduce function. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
compute, compute, compute, compute, compute, computeWithCtx, computeWithCtx, computeWithCtx, computeWithCtx, computeWithCtx, wrap
protected final Dataset<C extends Serializable,D extends AutoCloseable> delegate
compute
actions.public <R> R computeWithCtx(IgniteTriFunction<C,D,LearningEnvironment,R> map, IgniteBinaryOperator<R> reduce, R identity)
map
function to every partition data
, context
and partition
index in the dataset and then reduces map
results to final result by using the reduce
function.computeWithCtx
in interface Dataset<C extends Serializable,D extends AutoCloseable>
R
- Type of a result.map
- Function applied to every partition data
, context
and LearningEnvironment
.reduce
- Function applied to results of map
to get final result.identity
- Identity.public <R> R compute(IgniteBiFunction<D,LearningEnvironment,R> map, IgniteBinaryOperator<R> reduce, R identity)
map
function to every partition data
and LearningEnvironment
in the dataset and then reduces map
results to final result by using the reduce
function.compute
in interface Dataset<C extends Serializable,D extends AutoCloseable>
R
- Type of a result.map
- Function applied to every partition data
and LearningEnvironment
.reduce
- Function applied to results of map
to get final result.identity
- Identity.public void close() throws Exception
close
in interface AutoCloseable
Exception
GridGain In-Memory Computing Platform : ver. 8.9.15 Release Date : December 3 2024