Learn R Programming

rkeops (version 2.2.2)

fix_op_reduction: Fix internal reduction operation.

Description

Returns the internal reduction operation.

[Deprecated] fix_op_reduction() is not useful anymore because rkeops is using pykeops Python package as an internal engine where this is managed.

Usage

fix_op_reduction(reduction_op, with_weight = FALSE)

Value

A text string.

Arguments

reduction_op

A text string corresponding to a reduction.

with_weight

A boolean which is TRUE when there is an optional argument corresponding to a weight argument.

Author

Chloe Serre-Combe, Amelie Vernay

Details

fix_op_reduction(reduction_op, with_weight) will return the internal reduction operation according to reduction_op and a possible optional weight argument. Some advance operations defined at user level use, in fact, other internal reductions:

  • If reduction_op == "LogSumExp", the internal reduction operation is "Max_SumShiftExp" or "Max_SumShiftExpWeight" depending on with_weight;

  • If reduction_op == "SumSoftMax", the internal reduction operation is "Max_SumShiftExpWeight";

  • Else, for every other value of reduction_op, the internal reduction operation is reduction_op.