Evaluator

Evaluator()

An optimized evaluator of an expression.

Methods

Name Description
compile Compile the evaluator to a shared library using C++ and optionally inline assembly and load it.
evaluate Evaluate the expression for multiple inputs and return the result.
evaluate_complex Evaluate the expression for multiple inputs and return the result.
evaluate_complex_flat Evaluate the expression for multiple inputs that are flattened and return the flattened result.
evaluate_flat Evaluate the expression for multiple inputs that are flattened and return the flattened result.

compile

Evaluator.compile(function_name, filename, library_name, inline_asm=True, optimization_level=3, compiler_path=None)

Compile the evaluator to a shared library using C++ and optionally inline assembly and load it.

evaluate

Evaluator.evaluate(inputs)

Evaluate the expression for multiple inputs and return the result.

evaluate_complex

Evaluator.evaluate_complex(inputs)

Evaluate the expression for multiple inputs and return the result.

evaluate_complex_flat

Evaluator.evaluate_complex_flat(inputs)

Evaluate the expression for multiple inputs that are flattened and return the flattened result. This method has less overhead than evaluate_complex.

evaluate_flat

Evaluator.evaluate_flat(inputs)

Evaluate the expression for multiple inputs that are flattened and return the flattened result. This method has less overhead than evaluate.