aeppl.abstract.MeasurableElemwise#

class aeppl.abstract.MeasurableElemwise(scalar_op, *args, **kwargs)[source]#

Base class for Measurable Elemwise variables

Methods

MeasurableElemwise.L_op(inputs, outs, ograds)

Construct a graph for the L-operator.

MeasurableElemwise.R_op(inputs, eval_points)

Construct a graph for the R-operator.

MeasurableElemwise.__init__(scalar_op, ...)

param scalar_op

An instance of a subclass of ScalarOp which works uniquely

MeasurableElemwise.add_tag_trace([user_line])

Add tag.trace to a node or variable.

MeasurableElemwise.c_cleanup_code_struct(...)

Return an Apply-specific code string to be inserted in the struct cleanup code.

MeasurableElemwise.c_code(node, nodename, ...)

Return the C implementation of an Op.

MeasurableElemwise.c_code_cache_version()

Return a tuple of integers indicating the version of this Op.

MeasurableElemwise.c_code_cache_version_apply(node)

Return a tuple of integers indicating the version of this Op.

MeasurableElemwise.c_code_cleanup(node, ...)

Return C code to run after CLinkerOp.c_code, whether it failed or not.

MeasurableElemwise.c_compile_args(**kwargs)

Return the compilation argument "-fopenmp" if OpenMP is supported.

MeasurableElemwise.c_header_dirs(**kwargs)

Return a list of header search paths required by code returned by this class.

MeasurableElemwise.c_headers(**kwargs)

Return the header file name "omp.h" if OpenMP is supported.

MeasurableElemwise.c_init_code(**kwargs)

Return a list of code snippets to be inserted in module initialization.

MeasurableElemwise.c_init_code_apply(node, name)

Return a code string specific to the Apply to be inserted in the module initialization code.

MeasurableElemwise.c_init_code_struct(node, ...)

Return an Apply-specific code string to be inserted in the struct initialization code.

MeasurableElemwise.c_lib_dirs(**kwargs)

Return a list of library search paths required by code returned by this class.

MeasurableElemwise.c_libraries(**kwargs)

Return a list of libraries required by code returned by this class.

MeasurableElemwise.c_no_compile_args(**kwargs)

Return a list of incompatible gcc compiler arguments.

MeasurableElemwise.c_support_code(**kwargs)

Return utility code for use by a Variable or Op.

MeasurableElemwise.c_support_code_apply(...)

Return Apply-specialized utility code for use by an Op that will be inserted at global scope.

MeasurableElemwise.c_support_code_struct(...)

Return Apply-specific utility code for use by an Op that will be inserted at struct scope.

MeasurableElemwise.connection_pattern(node)

MeasurableElemwise.do_constant_folding(...)

Determine whether or not constant folding should be performed for the given node.

MeasurableElemwise.get_output_info(...)

Return the outputs dtype and broadcastable pattern and the dimshuffled inputs.

MeasurableElemwise.get_params(node)

Try to get parameters for the Op when Op.params_type is set to a ParamsType.

MeasurableElemwise.grad(inputs, output_grads)

Construct a graph for the gradient with respect to each input variable.

MeasurableElemwise.infer_shape(fgraph, node, ...)

rtype

List[Tuple[TensorVariable, ...]]

MeasurableElemwise.make_c_thunk(node, ...)

Create a thunk for a C implementation.

MeasurableElemwise.make_node(*inputs)

If the inputs have different number of dimensions, their shape is left-completed to the greatest number of dimensions with 1s using DimShuffle.

MeasurableElemwise.make_py_thunk(node, ...)

Make a Python thunk.

MeasurableElemwise.make_thunk(node, ...[, impl])

Create a thunk.

MeasurableElemwise.perform(node, inputs, ...)

Calculate the function on the inputs and put the variables in the output storage.

MeasurableElemwise.prepare_node(node, ...)

Make any special modifications that the Op needs before doing Op.make_thunk.

MeasurableElemwise.test_gxx_support()

Check if OpenMP is supported.

MeasurableElemwise.update_self_openmp()

Make sure self.openmp is not True if there is no OpenMP support in gxx.

Attributes

default_output

An int that specifies which output Op.__call__ should return.

destroy_map

A dict that maps output indices to the input indices upon which they operate in-place.

gxx_support_openmp

True/False after we tested this.

itypes

otypes

params_type

valid_scalar_types

view_map

A dict that maps output indices to the input indices of which they are a view.