pystencils.flow.operator.Operator#

class pystencils.flow.operator.Operator(graph, *, config=None)#
Parameters:
property kernel: Kernel | None#

Kernel IR of this operator

property func: KernelWrapper | None#

Executable kernel function of this operator

generate_code()#

Generate the intermediate representation of this operator’s code.

Raises:

RuntimeError – If code was already generated

clear()#

Clear the generated IR and compiled module, if present.

compile_code()#

Compile this operator’s executable module.

Internally calls generate_code if code was not already generated.

Raises:

RuntimeError – If the code was already compiled

clear_compiled_code()#

Clear the compiled code module. Does nothing if no compiled module is attached.