Package org.apache.sysds.runtime.data
Class LibTensorAgg
- java.lang.Object
- 
- org.apache.sysds.runtime.data.LibTensorAgg
 
- 
 public class LibTensorAgg extends Object 
- 
- 
Constructor SummaryConstructors Constructor Description LibTensorAgg()
 - 
Method SummaryAll Methods Static Methods Concrete Methods Modifier and Type Method Description static voidaggregateBinaryTensor(BasicTensorBlock in, BasicTensorBlock aggVal, AggregateOperator aop)Core incremental tensor aggregate (ak+) as used for uack+ and acrk+.static voidaggregateUnaryTensor(BasicTensorBlock in, BasicTensorBlock out, AggregateUnaryOperator uaop)Aggregate a tensor-block with the given unary operator.static booleanisSupportedUnaryAggregateOperator(AggregateUnaryOperator op)Determines whether the unary operator is supported.static booleansatisfiesMultiThreadingConstraints(BasicTensorBlock in, int k)Check if a aggregation fulfills the constraints to be split to multiple threads.
 
- 
- 
- 
Method Detail- 
satisfiesMultiThreadingConstraintspublic static boolean satisfiesMultiThreadingConstraints(BasicTensorBlock in, int k) Check if a aggregation fulfills the constraints to be split to multiple threads.- Parameters:
- in- the tensor block to be aggregated
- k- the number of threads
- Returns:
- true if aggregation should be done on multiple threads, false otherwise
 
 - 
aggregateUnaryTensorpublic static void aggregateUnaryTensor(BasicTensorBlock in, BasicTensorBlock out, AggregateUnaryOperator uaop) Aggregate a tensor-block with the given unary operator.- Parameters:
- in- the input tensor block
- out- the output tensor block containing the aggregated result
- uaop- the unary operation to apply
 
 - 
aggregateBinaryTensorpublic static void aggregateBinaryTensor(BasicTensorBlock in, BasicTensorBlock aggVal, AggregateOperator aop) Core incremental tensor aggregate (ak+) as used for uack+ and acrk+. Embedded correction values.- Parameters:
- in- partial aggregation
- aggVal- partial aggregation, also output (in will be added to this)
- aop- aggregation operator
 
 - 
isSupportedUnaryAggregateOperatorpublic static boolean isSupportedUnaryAggregateOperator(AggregateUnaryOperator op) Determines whether the unary operator is supported.- Parameters:
- op- the unary operator to check
- Returns:
- true if the operator is supported, false otherwise
 
 
- 
 
-