cirq.CircuitDiagramInfoArgs
A request for information on drawing an operation in a circuit diagram.
cirq.CircuitDiagramInfoArgs(
known_qubits: Optional[Iterable['cirq.Qid']],
known_qubit_count: Optional[int],
use_unicode_characters: bool,
precision: Optional[int],
label_map: Optional[Dict['cirq.LabelEntity', int]],
include_tags: bool = True,
transpose: bool = False
) -> None
Attributes |
known_qubits
|
The qubits the gate is being applied to. None means this
information is not known by the caller.
|
known_qubit_count
|
The number of qubits the gate is being applied to
None means this information is not known by the caller.
|
use_unicode_characters
|
If true, the wire symbols are permitted to
include unicode characters (as long as they work well in fixed
width fonts). If false, use only ascii characters. ASCII is
preferred in cases where UTF8 support is done poorly, or where
the fixed-width font being used to show the diagrams does not
properly handle unicode characters.
|
precision
|
The number of digits after the decimal to show for numbers in
the text diagram. None means use full precision.
|
label_map
|
The map from label entities to diagram positions.
|
include_tags
|
Whether to print tags from TaggedOperations.
|
transpose
|
Whether the circuit is to be drawn with time from left to
right (transpose is False), or from top to bottom.
|
Methods
copy
View source
copy()
View source
format_complex(
val: Union[sympy.Basic, int, float, 'cirq.TParamValComplex']
) -> str
View source
format_radians(
radians: Union[sympy.Basic, int, float]
) -> str
Returns angle in radians as a human-readable string.
View source
format_real(
val: Union[sympy.Basic, int, float]
) -> str
with_args
View source
with_args(
**kwargs
)
__eq__
View source
__eq__(
other: _SupportsValueEquality
) -> bool
__ne__
View source
__ne__(
other: _SupportsValueEquality
) -> bool
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-06-27 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-06-27 UTC."],[],[]]