pygsti.objects.WeightedGateString.to_pythonstr¶
-
WeightedGateString.
to_pythonstr
(gateLabels)¶ Convert this gate string into a python string, where each gate label is represented as a single character, starting with ‘A’ and contining down the alphabet. This can be useful for processing gate strings using python’s string tools (regex in particular).
Parameters: gateLabels (tuple) – tuple containing all the gate labels that will be mapped to alphabet characters, beginning with ‘A’. Returns: The converted gate string. Return type: string Examples
(‘Gx’,’Gx’,’Gy’,’Gx’) => “AABA”