boundlab.zonoq.Matmul#

class boundlab.zonoq.Matmul[source]#

Bases: OpHandler

ZonoQ × ZonoQ product: \(L_1 L_2\) exactly into the quadratic part; \(L Q\), \(Q L\) and \(Q Q\) terms box-bounded as noise (degree ≥ 3 has no representation here).

Methods

__init__

condition

Whether this handler applies to these operands (default: always).

handle

Transform the operands; sub-operations go through interp.<op> so the enclosing domain's handlers apply to them too.

override_handler

A copy of this handler that takes precedence over other when both are ready for the same call.

op: str = 'matmul'#
condition(x, y, **kwargs)[source]#

Whether this handler applies to these operands (default: always).

handle(interp, x, y, **kwargs)[source]#

Transform the operands; sub-operations go through interp.<op> so the enclosing domain’s handlers apply to them too.

__init__(op='matmul')#
override_handler(other)#

A copy of this handler that takes precedence over other when both are ready for the same call.

overrides: list[type[OpHandler]] = []#