Skip to content

Commit

Permalink
Regen with language output
Browse files Browse the repository at this point in the history
  • Loading branch information
Eric-Arellano committed Nov 1, 2024
1 parent 927b5c8 commit 997b139
Show file tree
Hide file tree
Showing 105 changed files with 299 additions and 299 deletions.
2 changes: 1 addition & 1 deletion docs/api/qiskit/dev/circuit.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -690,7 +690,7 @@ Consult [the control-flow construction documentation](qiskit.circuit.QuantumCirc

If two operations in a circuit commute, we can swap the order in which they are applied. This can allow for optimizations and simplifications, for example, if it allows to merge or cancel gates:

```python
```text
┌─────────┐ ┌─────────┐ ┌─────────┐
q_0: ┤ Rz(0.5) ├──■──┤ Rz(1.2) ├──■── q_0: ┤ Rz(1.7) ├
└─────────┘┌─┴─┐└──┬───┬──┘┌─┴─┐ = └──┬───┬──┘
Expand Down
146 changes: 73 additions & 73 deletions docs/api/qiskit/dev/circuit_library.mdx

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/api/qiskit/dev/passmanager.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ pm.run([123456789, 45654, 36785554])

Output:

```python
```text
[12346789, 464, 36784]
```

Expand Down Expand Up @@ -122,7 +122,7 @@ pm.run([123456789, 45654, 36785554])

Output:

```python
```text
[12346789, 45654, 36784]
```

Expand Down
20 changes: 10 additions & 10 deletions docs/api/qiskit/dev/pulse.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -820,7 +820,7 @@ with pulse.build(backend) as drive_sched:
print(d0)
```

```python
```text
DriveChannel(0)
```

Expand Down Expand Up @@ -1134,7 +1134,7 @@ drive_sched.draw()
print(pulse_prog)
```

```python
```text
ScheduleBlock(
ScheduleBlock(
Play(
Expand All @@ -1155,7 +1155,7 @@ drive_sched.draw()
print(pulse_prog.references)
```

```python
```text
ReferenceManager:
- ('block0', '634b3b50bd684e26a673af1fbd2d6c81'): ScheduleBlock(Play(Gaussian(...
```
Expand All @@ -1175,7 +1175,7 @@ drive_sched.draw()
print(pulse_prog)
```

```python
```text
ScheduleBlock(
ScheduleBlock(
Play(
Expand Down Expand Up @@ -1214,7 +1214,7 @@ drive_sched.draw()
print(pulse_prog)
```

```python
```text
ScheduleBlock(
ScheduleBlock(
Play(Gaussian(duration=160, amp=(0.1+0j), sigma=40), DriveChannel(0)),
Expand All @@ -1238,7 +1238,7 @@ drive_sched.draw()
print(pulse_prog)
```

```python
```text
ScheduleBlock(
Call(
Schedule(
Expand Down Expand Up @@ -1843,7 +1843,7 @@ with pulse.build(backend) as measure_sched:
print(mem_slot)
```

```python
```text
MemorySlot(0)
```

Expand Down Expand Up @@ -1998,7 +1998,7 @@ with pulse.build(backend) as u3_sched:
seconds, pulse.seconds_to_samples(1e-6)))
```

```python
```text
Number of qubits in backend: 1
There are 160 samples in 3.5555555555555554e-08 seconds
There are 1e-06 seconds in 4500 samples.
Expand Down Expand Up @@ -2049,7 +2049,7 @@ There are 1e-06 seconds in 4500 samples.
print(pulse.num_qubits())
```

```python
```text
2
```

Expand Down Expand Up @@ -2083,7 +2083,7 @@ There are 1e-06 seconds in 4500 samples.
print(pulse.qubit_channels(0))
```

```python
```text
{MeasureChannel(0), ControlChannel(0), DriveChannel(0), AcquireChannel(0), ControlChannel(1)}
```

Expand Down
8 changes: 4 additions & 4 deletions docs/api/qiskit/dev/qasm2.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ qc.measure([0, 1], [0, 1])
print(qiskit.qasm2.dumps(qc))
```

```python
```text
OPENQASM 2.0;
include "qelib1.inc";
qreg q[2];
Expand Down Expand Up @@ -291,7 +291,7 @@ circuit = qiskit.qasm2.loads(program)
circuit.draw()
```

```python
```text
┌───┐ ┌─┐
q_0: ┤ H ├──■──┤M├───
└───┘┌─┴─┐└╥┘┌─┐
Expand Down Expand Up @@ -399,7 +399,7 @@ circuit = loads(program, custom_classical=customs)

As a language, OpenQASM 2 does not have a way to specify the global phase of a complete program, nor of particular gate definitions. This means that parsers of the language may interpret particular gates with a different global phase than what you might expect. For example, the *de facto* standard library of OpenQASM 2 `qelib1.inc` contains definitions of `u1` and `rz` as follows:

```python
```text
gate u1(lambda) q {
U(0, 0, lambda) q;
}
Expand Down Expand Up @@ -444,7 +444,7 @@ This will use Qiskit’s [`PhaseGate`](qiskit.circuit.library.PhaseGate "qiskit.
Operator(qasm2.loads(program, custom_instructions=custom))
```

```python
```text
Operator([[1.000000e+00+0.j, 0.000000e+00+0.j],
[0.000000e+00+0.j, 6.123234e-17+1.j]],
input_dims=(2,), output_dims=(2,))
Expand Down
2 changes: 1 addition & 1 deletion docs/api/qiskit/dev/qasm3.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ Currently only two high-level functions are offered, as Qiskit support for impor
<Admonition title="Note" type="note">
While we are still in the exploratory release period, to use either function, the package `qiskit_qasm3_import` must be installed. This can be done by installing Qiskit with the `qasm3-import` extra, such as by:

```python
```text
pip install qiskit[qasm3-import]
```

Expand Down
32 changes: 16 additions & 16 deletions docs/api/qiskit/dev/qiskit.circuit.QuantumCircuit.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -1232,7 +1232,7 @@ python_api_name: qiskit.circuit.QuantumCircuit
>>> lhs.compose(rhs, qubits=[3, 2], inplace=True)
```

```python
```text
┌───┐ ┌─────┐ ┌───┐
lqr_1_0: ───┤ H ├─── rqr_0: ──■──┤ Tdg ├ lqr_1_0: ───┤ H ├───────────────
├───┤ ┌─┴─┐└─────┘ ├───┤
Expand All @@ -1259,7 +1259,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

Remember that in the little-endian convention the leftmost operation will be at the bottom of the circuit. See also [the docs](/guides/construct-circuits) for more information.

```python
```text
┌────────┐ ┌─────┐ ┌─────┐
q_0: ┤ bottom ├ ⊗ q_0: ┤ top ├ = q_0: ─┤ top ├──
└────────┘ └─────┘ ┌┴─────┴─┐
Expand Down Expand Up @@ -1916,7 +1916,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

output:

```python
```text
┌──────────────────────────────┐
q_0: ┤ Initialize(0.70711,-0.70711) ├
└──────────────────────────────┘
Expand All @@ -1935,7 +1935,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

output:

```python
```text
┌──────────────────┐
q_0: ┤0 ├
│ Initialize(0,1) │
Expand All @@ -1956,7 +1956,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

output:

```python
```text
┌────────────────────────────────────┐
q_0: ┤0 ├
│ Initialize(0,0.70711,-0.70711j,0) │
Expand Down Expand Up @@ -2137,7 +2137,7 @@ python_api_name: qiskit.circuit.QuantumCircuit
circuit.draw()
```

```python
```text
┌───┐┌─┐
q: ┤ H ├┤M├
└───┘└╥┘
Expand Down Expand Up @@ -2284,7 +2284,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

output:

```python
```text
┌─────────────────────────────────────┐
q_0: ┤ State Preparation(0.70711,-0.70711) ├
└─────────────────────────────────────┘
Expand All @@ -2303,7 +2303,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

output:

```python
```text
┌─────────────────────────┐
q_0: ┤0 ├
│ State Preparation(0,1) │
Expand All @@ -2324,7 +2324,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

output:

```python
```text
┌───────────────────────────────────────────┐
q_0: ┤0 ├
│ State Preparation(0,0.70711,-0.70711j,0) │
Expand Down Expand Up @@ -3442,7 +3442,7 @@ python_api_name: qiskit.circuit.QuantumCircuit
qc.count_ops()
```

```python
```text
OrderedDict([('cx', 8), ('h', 5), ('x', 3), ('swap', 3)])
```

Expand Down Expand Up @@ -3752,7 +3752,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

input:

```python
```text
┌───┐
q_0: ┤ H ├─────■──────
└───┘┌────┴─────┐
Expand All @@ -3762,7 +3762,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

output:

```python
```text
┌───┐
q_0: ──────■──────┤ H ├
┌─────┴─────┐└───┘
Expand Down Expand Up @@ -3835,7 +3835,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

input:

```python
```text
┌───┐
q_0: ┤ H ├─────■──────
└───┘┌────┴─────┐
Expand All @@ -3845,7 +3845,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

output:

```python
```text
┌───┐
q_0: ─────■──────┤ H ├
┌────┴─────┐└───┘
Expand Down Expand Up @@ -4004,7 +4004,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

input:

```python
```text
┌───┐
a_0: ┤ H ├──■─────────────────
└───┘┌─┴─┐
Expand All @@ -4020,7 +4020,7 @@ python_api_name: qiskit.circuit.QuantumCircuit

output:

```python
```text
┌───┐
b_0: ────────────────────┤ X ├
┌───┐└─┬─┘
Expand Down
4 changes: 2 additions & 2 deletions docs/api/qiskit/dev/qiskit.circuit.library.CCXGate.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ python_api_name: qiskit.circuit.library.CCXGate

**Circuit symbol:**

```python
```text
q_0: ──■──
q_1: ──■──
Expand Down Expand Up @@ -46,7 +46,7 @@ $$
<Admonition title="Note" type="note">
In Qiskit’s convention, higher qubit indices are more significant (little endian convention). In many textbooks, controlled gates are presented with the assumption of more significant qubits as control, which in our case would be q\_2 and q\_1. Thus a textbook matrix for this gate will be:

```python
```text
┌───┐
q_0: ┤ X ├
└─┬─┘
Expand Down
2 changes: 1 addition & 1 deletion docs/api/qiskit/dev/qiskit.circuit.library.CCZGate.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ python_api_name: qiskit.circuit.library.CCZGate

**Circuit symbol:**

```python
```text
q_0: ─■─
q_1: ─■─
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ python_api_name: qiskit.circuit.library.CDKMRippleCarryAdder

As an example, a ripple-carry adder circuit that performs addition on two 3-qubit sized registers with a carry-in bit (`kind="full"`) is as follows:

```python
```text
┌──────┐ ┌──────┐
cin_0: ┤2 ├─────────────────────────────────────┤2 ├
│ │┌──────┐ ┌──────┐│ │
Expand All @@ -41,7 +41,7 @@ python_api_name: qiskit.circuit.library.CDKMRippleCarryAdder

The circuit diagram for the fixed-point adder (`kind="fixed"`) on 3-qubit sized inputs is

```python
```text
┌──────┐┌──────┐ ┌──────┐┌──────┐
a_0: ┤0 ├┤2 ├────────────────┤2 ├┤0 ├
│ ││ │┌──────┐┌──────┐│ ││ │
Expand Down
4 changes: 2 additions & 2 deletions docs/api/qiskit/dev/qiskit.circuit.library.CHGate.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ python_api_name: qiskit.circuit.library.CHGate

**Circuit symbol:**

```python
```text
q_0: ──■──
┌─┴─┐
q_1: ┤ H ├
Expand All @@ -42,7 +42,7 @@ $$
<Admonition title="Note" type="note">
In Qiskit’s convention, higher qubit indices are more significant (little endian convention). In many textbooks, controlled gates are presented with the assumption of more significant qubits as control, which in our case would be q\_1. Thus a textbook matrix for this gate will be:

```python
```text
┌───┐
q_0: ┤ H ├
└─┬─┘
Expand Down
2 changes: 1 addition & 1 deletion docs/api/qiskit/dev/qiskit.circuit.library.CPhaseGate.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ python_api_name: qiskit.circuit.library.CPhaseGate

**Circuit symbol:**

```python
```text
q_0: ─■──
│θ
q_1: ─■──
Expand Down
4 changes: 2 additions & 2 deletions docs/api/qiskit/dev/qiskit.circuit.library.CRXGate.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ python_api_name: qiskit.circuit.library.CRXGate

**Circuit symbol:**

```python
```text
q_0: ────■────
┌───┴───┐
q_1: ┤ Rx(ϴ) ├
Expand All @@ -42,7 +42,7 @@ $$
<Admonition title="Note" type="note">
In Qiskit’s convention, higher qubit indices are more significant (little endian convention). In many textbooks, controlled gates are presented with the assumption of more significant qubits as control, which in our case would be q\_1. Thus a textbook matrix for this gate will be:

```python
```text
┌───────┐
q_0: ┤ Rx(ϴ) ├
└───┬───┘
Expand Down
Loading

0 comments on commit 997b139

Please sign in to comment.