cirq.ExpressionMap

class cirq.ExpressionMap(*args, **kwargs)[source]
A dictionary with sympy expressions and symbols for keys and sympy
symbols for values.
This is returned by cirq.flatten. See ExpressionMap.transform_sweep and
ExpressionMap.transform_params.
__init__(*args, **kwargs)[source]

Initializes the ExpressionMap.

Takes the same arguments as the builtin dict. Keys must be sympy
expressions or symbols (instances of sympy.Basic).

Methods

clear()

copy()

fromkeys([value])

Returns a new dict with keys from iterable and values equal to value.

get(k[,d])

items()

keys()

pop(k[,d])

If key is not found, d is returned if given, otherwise KeyError is raised

popitem()

2-tuple; but raise KeyError if D is empty.

setdefault(k[,d])

transform_params(params)

Returns a ParamResolver to use with a circuit flattened earlier

transform_sweep(sweep)

Returns a sweep to use with a circuit flattened earlier with

update([E, ]**F)

If E is present and has a .keys() method, then does: for k in E: D[k]

values()