cirq.symbolize_single_qubit_gates_by_indexed_tags

Symbolizes single qubit operations by indexed tags prefixed by symbolize_tag.prefix.

>>> from cirq import transformers
>>> q0, q1 = cirq.LineQubit.range(2)
>>> c = cirq.Circuit(
...         cirq.X(q0).with_tags("phxz_0"),
...         cirq.CZ(q0,q1),
...         cirq.Y(q0).with_tags("phxz_1"),
...         cirq.X(q0))
>>> print(c)
</td>
</tr>
<tr>
<td>
`0`<a id="0"></a>
</td>
<td>
───X[phxz_0]───@───Y[phxz_1]───X───

</td>
</tr><tr>
<td>
`1`<a id="1"></a>
</td>
<td>
───────────────@───────────────────
>>> new_circuit = cirq.symbolize_single_qubit_gates_by_indexed_tags(
...     c, symbolize_tag=transformers.SymbolizeTag(prefix="phxz"))
>>> print(new_circuit)
</td>
</tr><tr>
<td>
`0`<a id="0"></a>
</td>
<td>
───PhXZ(a=a0,x=x0,z=z0)───@───PhXZ(a=a1,x=x1,z=z1)───X───

</td>
</tr><tr>
<td>
`1`<a id="1"></a>
</td>
<td>
──────────────────────────@──────────────────────────────

circuit Input circuit to apply the transformations on. The input circuit is not mutated.
context cirq.TransformerContext storing common configurable options for transformers.
symbolize_tag The tag info used to symbolize the phxz gate. Prefix is required.

Copy of the transformed input circuit.