diff options
Diffstat (limited to 'vespajlib/src/test/java/com/yahoo/tensor/TensorFunctionBenchmark.java')
-rw-r--r-- | vespajlib/src/test/java/com/yahoo/tensor/TensorFunctionBenchmark.java | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/vespajlib/src/test/java/com/yahoo/tensor/TensorFunctionBenchmark.java b/vespajlib/src/test/java/com/yahoo/tensor/TensorFunctionBenchmark.java index 3c07dd9e6d4..b3c6fbc6862 100644 --- a/vespajlib/src/test/java/com/yahoo/tensor/TensorFunctionBenchmark.java +++ b/vespajlib/src/test/java/com/yahoo/tensor/TensorFunctionBenchmark.java @@ -2,7 +2,7 @@ package com.yahoo.tensor; import com.yahoo.tensor.evaluation.MapEvaluationContext; -import com.yahoo.tensor.evaluation.TypeContext; +import com.yahoo.tensor.evaluation.Name; import com.yahoo.tensor.evaluation.VariableTensor; import com.yahoo.tensor.functions.ConstantTensor; import com.yahoo.tensor.functions.Join; @@ -50,10 +50,10 @@ public class TensorFunctionBenchmark { private double dotProduct(Tensor tensor, List<Tensor> tensors) { double largest = Double.MIN_VALUE; - TensorFunction<TypeContext.Name> dotProductFunction = new Reduce<>(new Join<>(new ConstantTensor<>(tensor), - new VariableTensor<>("argument"), (a, b) -> a * b), - Reduce.Aggregator.sum).toPrimitive(); - MapEvaluationContext<TypeContext.Name> context = new MapEvaluationContext<>(); + TensorFunction<Name> dotProductFunction = new Reduce<>(new Join<>(new ConstantTensor<>(tensor), + new VariableTensor<>("argument"), (a, b) -> a * b), + Reduce.Aggregator.sum).toPrimitive(); + MapEvaluationContext<Name> context = new MapEvaluationContext<>(); for (Tensor tensorElement : tensors) { // tensors.size() = 1 for larger tensor context.put("argument", tensorElement); |