Package hedge :: Module compiler :: Class OperatorCompilerBase
[hide private]
[frames] | no frames]

Class OperatorCompilerBase

source code


Nested Classes [hide private]
  FluxRecord
  FluxBatch
Instance Methods [hide private]
 
__init__(self, prefix='_expr', max_vectors_in_batch_expr=None)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
dep_mapper_factory(self, include_subscripts=False) source code
 
get_contained_fluxes(self, expr)
Recursively enumerate all flux expressions in the expression tree `expr`.
source code
 
collect_diff_ops(self, expr) source code
 
collect_flux_exchange_ops(self, expr) source code
 
__call__(self, expr) source code
 
get_var_name(self) source code
 
map_common_subexpression(self, expr) source code
 
map_operator_binding(self, expr) source code
 
map_diff_op_binding(self, expr) source code
 
map_mass_op_binding(self, expr) source code
 
map_flux_exchange_op_binding(self, expr) source code
 
map_planned_flux(self, expr) source code
 
assign_to_new_var(self, expr, priority=0) source code
 
make_assign(self, name, expr, priority) source code
 
make_flux_batch_assign(self, names, fluxes, kind) source code
 
aggregate_assignments(self, instructions, result) source code

Inherited from optemplate.IdentityMapperMixin: map_boundarize, map_boundary_pair, map_diff_base, map_elementwise_max, map_flux_base, map_flux_exchange, map_mass_base, map_normal_component, map_scalar_parameter

Inherited from optemplate.LocalOpReducerMixin: map_diff, map_inverse_mass, map_mass, map_minv_st, map_stiffness, map_stiffness_t

Inherited from optemplate.FluxOpReducerMixin: map_flux, map_lift

Inherited from pymbolic.mapper.IdentityMapperBase: map_call, map_constant, map_function_symbol, map_list, map_lookup, map_negation, map_numpy_array, map_polynomial, map_power, map_product, map_quotient, map_subscript, map_sum, map_variable, map_vector

Inherited from pymbolic.mapper.RecursiveMapper: rec

Inherited from pymbolic.mapper.Mapper: handle_unsupported_expression, map_foreign, map_rational

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __str__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, prefix='_expr', max_vectors_in_batch_expr=None)
(Constructor)

source code 

x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Overrides: object.__init__
(inherited documentation)

dep_mapper_factory(self, include_subscripts=False)

source code 
Decorators:
  • @memoize_method

get_contained_fluxes(self, expr)

source code 

Recursively enumerate all flux expressions in the expression tree `expr`. The returned list consists of `ExecutionPlanner.FluxRecord` instances with fields `flux_expr` and `dependencies`.

__call__(self, expr)
(Call operator)

source code 
Overrides: pymbolic.mapper.Mapper.__call__

map_common_subexpression(self, expr)

source code 
Overrides: pymbolic.mapper.IdentityMapperBase.map_common_subexpression

map_operator_binding(self, expr)

source code 
Overrides: optemplate.IdentityMapperMixin.map_operator_binding