Skip to content

Commit

Permalink
Revert to old version of API docs (#68)
Browse files Browse the repository at this point in the history
There were a couple of regressions in the API generation script since we
last ran it in closed source. Those will be fixed in follow up PRs. See
#67.

This PR was created by simply copying and pasting the `api/` folders
from closed source. They are generated files, so we don't have to worry
about attribution.
  • Loading branch information
Eric-Arellano authored Oct 3, 2023
1 parent ab783b4 commit f542c76
Show file tree
Hide file tree
Showing 283 changed files with 1,058 additions and 675 deletions.
6 changes: 1 addition & 5 deletions docs/api/qiskit-ibm-provider/_toc.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"title": "Qiskit IBM Provider",
"subtitle": "v0.7.0",
"subtitle": "v0.6.3",
"children": [
{
"title": "qiskit_ibm_provider",
Expand Down Expand Up @@ -57,10 +57,6 @@
"title": "qiskit_ibm_provider.jupyter",
"url": "/api/qiskit-ibm-provider/ibm_jupyter"
},
{
"title": "Session",
"url": "/api/qiskit-ibm-provider/qiskit_ibm_provider.Session"
},
{
"title": "qiskit_ibm_provider.job",
"children": [
Expand Down
1 change: 0 additions & 1 deletion docs/api/qiskit-ibm-provider/ibm_provider.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ logging.getLogger('qiskit_ibm_provider').setLevel(logging.WARNING)
| [`IBMProvider`](qiskit_ibm_provider.IBMProvider "qiskit_ibm_provider.IBMProvider")(\[token, url, name, instance, ...]) | Provides access to the IBM Quantum services available to an account. |
| [`IBMBackend`](qiskit_ibm_provider.IBMBackend "qiskit_ibm_provider.IBMBackend")(configuration, provider, api\_client) | Backend class interfacing with an IBM Quantum device. |
| [`IBMBackendService`](qiskit_ibm_provider.IBMBackendService "qiskit_ibm_provider.IBMBackendService")(provider, hgp) | Backend namespace for an IBM Quantum account. |
| [`Session`](qiskit_ibm_provider.Session "qiskit_ibm_provider.Session")(\[max\_time]) | Class for creating a flexible Qiskit Runtime session. |

## Exceptions

Expand Down
84 changes: 21 additions & 63 deletions docs/api/qiskit-ibm-provider/qiskit_ibm_provider.IBMBackend.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ python_api_name: qiskit_ibm_provider.IBMBackend

Backend class interfacing with an IBM Quantum device.

You can run experiments on a backend using the [`run()`](qiskit_ibm_provider.IBMBackend#run "qiskit_ibm_provider.IBMBackend.run") method. The [`run()`](qiskit_ibm_provider.IBMBackend#run "qiskit_ibm_provider.IBMBackend.run") method takes one or more [`QuantumCircuit`](/api/qiskit/qiskit.circuit.QuantumCircuit.html#qiskit.circuit.QuantumCircuit "(in Qiskit v0.44)") and returns an `IBMJob` instance that represents the submitted job. Each job has a unique job ID, which can later be used to retrieve the job. An example of this flow:
You can run experiments on a backend using the [`run()`](qiskit_ibm_provider.IBMBackend#run "qiskit_ibm_provider.IBMBackend.run") method. The [`run()`](qiskit_ibm_provider.IBMBackend#run "qiskit_ibm_provider.IBMBackend.run") method takes one or more `QuantumCircuit` and returns an `IBMJob` instance that represents the submitted job. Each job has a unique job ID, which can later be used to retrieve the job. An example of this flow:

```python
from qiskit import transpile
Expand All @@ -34,7 +34,7 @@ retrieved_job = provider.backend.retrieve_job(job.job_id())
* You should not instantiate the `IBMBackend` class directly. Instead, use the methods provided by an [`IBMProvider`](qiskit_ibm_provider.IBMProvider "qiskit_ibm_provider.IBMProvider") instance to retrieve and handle backends.
</Admonition>

Other methods return information about the backend. For example, the [`status()`](qiskit_ibm_provider.IBMBackend#status "qiskit_ibm_provider.IBMBackend.status") method returns a [`BackendStatus`](/api/qiskit/qiskit.providers.models.BackendStatus.html#qiskit.providers.models.BackendStatus "(in Qiskit v0.44)") instance. The instance contains the `operational` and `pending_jobs` attributes, which state whether the backend is operational and also the number of jobs in the server queue for the backend, respectively:
Other methods return information about the backend. For example, the [`status()`](qiskit_ibm_provider.IBMBackend#status "qiskit_ibm_provider.IBMBackend.status") method returns a `BackendStatus` instance. The instance contains the `operational` and `pending_jobs` attributes, which state whether the backend is operational and also the number of jobs in the server queue for the backend, respectively:

```python
status = backend.status()
Expand All @@ -50,7 +50,7 @@ jobs_in_queue = status.pending_jobs

* num\_qubits: number of qubits.

* target: A [`qiskit.transpiler.Target`](/api/qiskit/qiskit.transpiler.Target.html#qiskit.transpiler.Target "(in Qiskit v0.44)") object for the backend.
* target: A `qiskit.transpiler.Target` object for the backend.

* basis\_gates: list of basis gates names on the backend.

Expand Down Expand Up @@ -144,7 +144,7 @@ IBMBackend constructor.

**Parameters**

* **configuration** (`Union`\[[`QasmBackendConfiguration`](/api/qiskit/qiskit.providers.models.QasmBackendConfiguration.html#qiskit.providers.models.QasmBackendConfiguration "(in Qiskit v0.44)"), [`PulseBackendConfiguration`](/api/qiskit/qiskit.providers.models.PulseBackendConfiguration.html#qiskit.providers.models.PulseBackendConfiguration "(in Qiskit v0.44)")]) – Backend configuration.
* **configuration** (`Union`\[`QasmBackendConfiguration`, `PulseBackendConfiguration`]) – Backend configuration.
* **provider** ([`IBMProvider`](qiskit_ibm_provider.IBMProvider "qiskit_ibm_provider.ibm_provider.IBMProvider")) – IBM Quantum account provider.
* **api\_client** (`AccountClient`) – IBM Quantum client used to communicate with the server.

Expand All @@ -154,7 +154,7 @@ IBMBackend constructor.

### coupling\_map

Return the [`CouplingMap`](/api/qiskit/qiskit.transpiler.CouplingMap.html#qiskit.transpiler.CouplingMap "(in Qiskit v0.44)") object
Return the `CouplingMap` object

<span id="ibmbackend-dt" />

Expand Down Expand Up @@ -198,13 +198,13 @@ Return the system time resolution of output signals :returns: The output signal

### instruction\_durations

Return the [`InstructionDurations`](/api/qiskit/qiskit.transpiler.InstructionDurations.html#qiskit.transpiler.InstructionDurations "(in Qiskit v0.44)") object.
Return the `InstructionDurations` object.

<span id="ibmbackend-instruction-schedule-map" />

### instruction\_schedule\_map

Return the [`InstructionScheduleMap`](/api/qiskit/qiskit.pulse.InstructionScheduleMap.html#qiskit.pulse.InstructionScheduleMap "(in Qiskit v0.44)") for the instructions defined in this backend’s target.
Return the `InstructionScheduleMap` for the instructions defined in this backend’s target.

<span id="ibmbackend-instructions" />

Expand All @@ -218,7 +218,7 @@ A list of Instruction tuples on the backend of the form `(instruction, (qubits)`

**Return type**

`List`\[`Tuple`\[[`Instruction`](/api/qiskit/qiskit.circuit.Instruction.html#qiskit.circuit.Instruction "(in Qiskit v0.44)"), `Tuple`\[`int`]]]
`List`\[`Tuple`\[`Instruction`, `Tuple`\[`int`]]]

<span id="ibmbackend-max-circuits" />

Expand Down Expand Up @@ -280,11 +280,11 @@ A list of instruction names that the backend supports.

`List[Instruction]`

A list of [`Instruction`](/api/qiskit/qiskit.circuit.Instruction.html#qiskit.circuit.Instruction "(in Qiskit v0.44)") instances that the backend supports.
A list of `Instruction` instances that the backend supports.

**Return type**

`List`\[[`Instruction`](/api/qiskit/qiskit.circuit.Instruction.html#qiskit.circuit.Instruction "(in Qiskit v0.44)")]
`List`\[`Instruction`]

<span id="ibmbackend-options" />

Expand All @@ -308,20 +308,6 @@ the Provider responsible for the backend.

Provider

<span id="ibmbackend-session" />

### session

<span id="qiskit_ibm_provider.IBMBackend.session" />

`Session`

Return session

**Return type**

[`Session`](qiskit_ibm_provider.Session "qiskit_ibm_provider.session.Session")

<span id="ibmbackend-target" />

### target
Expand All @@ -330,7 +316,7 @@ Return session

`Target`

A [`qiskit.transpiler.Target`](/api/qiskit/qiskit.transpiler.Target.html#qiskit.transpiler.Target "(in Qiskit v0.44)") object for the backend. :rtype: [`Target`](/api/qiskit/qiskit.transpiler.Target.html#qiskit.transpiler.Target "(in Qiskit v0.44)") :returns: Target
A `qiskit.transpiler.Target` object for the backend. :rtype: `Target` :returns: Target

<span id="ibmbackend-version" />

Expand Down Expand Up @@ -360,20 +346,6 @@ The Qubit measurement acquisition line.

AcquireChannel

<span id="ibmbackend-cancel-session" />

### cancel\_session

<span id="qiskit_ibm_provider.IBMBackend.cancel_session" />

`IBMBackend.cancel_session()`

Cancel session. All pending jobs will be cancelled.

**Return type**

`None`

<span id="ibmbackend-configuration" />

### configuration
Expand All @@ -390,7 +362,7 @@ The schema for backend configuration can be found in [Qiskit/ibm-quantum-schemas

**Return type**

`Union`\[[`QasmBackendConfiguration`](/api/qiskit/qiskit.providers.models.QasmBackendConfiguration.html#qiskit.providers.models.QasmBackendConfiguration "(in Qiskit v0.44)"), [`PulseBackendConfiguration`](/api/qiskit/qiskit.providers.models.PulseBackendConfiguration.html#qiskit.providers.models.PulseBackendConfiguration "(in Qiskit v0.44)")]
`Union`\[`QasmBackendConfiguration`, `PulseBackendConfiguration`]

**Returns**

Expand Down Expand Up @@ -438,7 +410,7 @@ The schema for default pulse configuration can be found in [Qiskit/ibm-quantum-s

**Return type**

`Optional`\[[`PulseDefaults`](/api/qiskit/qiskit.providers.models.PulseDefaults.html#qiskit.providers.models.PulseDefaults "(in Qiskit v0.44)")]
`Optional`\[`PulseDefaults`]

**Returns**

Expand Down Expand Up @@ -468,7 +440,7 @@ DriveChannel

<span id="qiskit_ibm_provider.IBMBackend.get_translation_stage_plugin" />

`classmethod IBMBackend.get_translation_stage_plugin()`
`IBMBackend.get_translation_stage_plugin()`

Return the default translation stage plugin name for IBM backends.

Expand All @@ -494,20 +466,6 @@ The Qubit measurement stimulus line

MeasureChannel

<span id="ibmbackend-open-session" />

### open\_session

<span id="qiskit_ibm_provider.IBMBackend.open_session" />

`IBMBackend.open_session(max_time=None)`

Open session

**Return type**

[`Session`](qiskit_ibm_provider.Session "qiskit_ibm_provider.session.Session")

<span id="ibmbackend-properties" />

### properties
Expand All @@ -525,11 +483,11 @@ The schema for backend properties can be found in [Qiskit/ibm-quantum-schemas](h
**Parameters**

* **refresh** (`bool`) – If `True`, re-query the server for the backend properties. Otherwise, return a cached version.
* **datetime** (`Optional`\[`datetime`]) – By specifying datetime, this function returns an instance of the [`BackendProperties`](/api/qiskit/qiskit.providers.models.BackendProperties.html#qiskit.providers.models.BackendProperties "(in Qiskit v0.44)") whose timestamp is closest to, but older than, the specified datetime.
* **datetime** (`Optional`\[`datetime`]) – By specifying datetime, this function returns an instance of the `BackendProperties` whose timestamp is closest to, but older than, the specified datetime.

**Return type**

`Optional`\[[`BackendProperties`](/api/qiskit/qiskit.providers.models.BackendProperties.html#qiskit.providers.models.BackendProperties "(in Qiskit v0.44)")]
`Optional`\[`BackendProperties`]

**Returns**

Expand Down Expand Up @@ -579,13 +537,13 @@ Run on the backend. If a keyword specified here is also present in the `options`

**Parameters**

* **circuits** (`Union`\[[`QuantumCircuit`](/api/qiskit/qiskit.circuit.QuantumCircuit.html#qiskit.circuit.QuantumCircuit "(in Qiskit v0.44)"), [`Schedule`](/api/qiskit/qiskit.pulse.Schedule.html#qiskit.pulse.Schedule "(in Qiskit v0.44)"), `str`, `List`\[`Union`\[[`QuantumCircuit`](/api/qiskit/qiskit.circuit.QuantumCircuit.html#qiskit.circuit.QuantumCircuit "(in Qiskit v0.44)"), [`Schedule`](/api/qiskit/qiskit.pulse.Schedule.html#qiskit.pulse.Schedule "(in Qiskit v0.44)"), `str`]]]) – An individual or a list of `QuantumCircuit`. [`Schedule`](/api/qiskit/qiskit.pulse.Schedule.html#qiskit.pulse.Schedule "(in Qiskit v0.44)") is no longer supported. Use `pulse gates` instead. See [tutorial](https://qiskit.org/documentation/tutorials/circuits_advanced/05_pulse_gates.html) on how to use pulse gates.
* **circuits** (`Union`\[`QuantumCircuit`, `Schedule`, `str`, `List`\[`Union`\[`QuantumCircuit`, `Schedule`, `str`]]]) – An individual or a list of `QuantumCircuit`. `Schedule` is no longer supported. Use `pulse gates` instead. See [tutorial](https://qiskit.org/documentation/tutorials/circuits_advanced/05_pulse_gates.html) on how to use pulse gates.

* **dynamic** (`Optional`\[`bool`]) – Whether the circuit is dynamic (uses in-circuit conditionals)

* **job\_tags** (`Optional`\[`List`\[`str`]]) – Tags to be assigned to the job. The tags can subsequently be used as a filter in the `jobs()` function call.

* **init\_circuit** (`Optional`\[[`QuantumCircuit`](/api/qiskit/qiskit.circuit.QuantumCircuit.html#qiskit.circuit.QuantumCircuit "(in Qiskit v0.44)")]) – A quantum circuit to execute for initializing qubits before each circuit. If specified, `init_num_resets` is ignored. Applicable only if `dynamic=True` is specified.
* **init\_circuit** (`Optional`\[`QuantumCircuit`]) – A quantum circuit to execute for initializing qubits before each circuit. If specified, `init_num_resets` is ignored. Applicable only if `dynamic=True` is specified.

* **init\_num\_resets** (`Optional`\[`int`]) – The number of qubit resets to insert before each circuit execution.

Expand Down Expand Up @@ -681,12 +639,12 @@ This method is used to update the options of a backend. If you need to change an
Return the backend status.

<Admonition title="Note" type="note">
If the returned [`BackendStatus`](/api/qiskit/qiskit.providers.models.BackendStatus.html#qiskit.providers.models.BackendStatus "(in Qiskit v0.44)") instance has `operational=True` but `status_msg="internal"`, then the backend is accepting jobs but not processing them.
If the returned `BackendStatus` instance has `operational=True` but `status_msg="internal"`, then the backend is accepting jobs but not processing them.
</Admonition>

**Return type**

[`BackendStatus`](/api/qiskit/qiskit.providers.models.BackendStatus.html#qiskit.providers.models.BackendStatus "(in Qiskit v0.44)")
`BackendStatus`

**Returns**

Expand All @@ -704,5 +662,5 @@ The status of the backend.

`IBMBackend.target_history(datetime=None)`

A [`qiskit.transpiler.Target`](/api/qiskit/qiskit.transpiler.Target.html#qiskit.transpiler.Target "(in Qiskit v0.44)") object for the backend. :rtype: [`Target`](/api/qiskit/qiskit.transpiler.Target.html#qiskit.transpiler.Target "(in Qiskit v0.44)") :returns: Target with properties found on datetime
A `qiskit.transpiler.Target` object for the backend. :rtype: `Target` :returns: Target with properties found on datetime

Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ Retrieve jobs that match the given filters and paginate the results if desired.
* **limit** (`Optional`\[`int`]) – Number of jobs to retrieve. `None` means no limit. Note that the number of sub-jobs within a composite job count towards the limit.
* **skip** (`int`) – Starting index for the job retrieval.
* **backend\_name** (`Optional`\[`str`]) – Name of the backend to retrieve jobs from.
* **status** (`Union`\[`Literal`\[‘pending’, ‘completed’], `List`\[`Union`\[[`JobStatus`](/api/qiskit/qiskit.providers.JobStatus.html#qiskit.providers.JobStatus "(in Qiskit v0.44)"), `str`]], [`JobStatus`](/api/qiskit/qiskit.providers.JobStatus.html#qiskit.providers.JobStatus "(in Qiskit v0.44)"), `str`, `None`]) – Filter jobs with either “pending” or “completed” status. You can also specify by
* **status** (`Union`\[`Literal`\[‘pending’, ‘completed’], `List`\[`Union`\[`JobStatus`, `str`]], `JobStatus`, `str`, `None`]) – Filter jobs with either “pending” or “completed” status. You can also specify by
* **example** (*exact status. For*) – or status=\[“RUNNING”, “ERROR”].
* **status="RUNNING"** (*status=JobStatus.RUNNING or*) – or status=\[“RUNNING”, “ERROR”].
* **start\_datetime** (`Optional`\[`datetime`]) – Filter by the given start date, in local time. This is used to find jobs whose creation dates are after (greater than or equal to) this local date/time.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,6 @@ The [`get_backend()`](qiskit_ibm_provider.IBMProvider#get_backend "qiskit_ibm_pr
simulator_backend = provider.get_backend('ibmq_qasm_simulator')
```

IBMBackend’s are uniquely identified by their name. If you invoke [`get_backend()`](qiskit_ibm_provider.IBMProvider#get_backend "qiskit_ibm_provider.IBMProvider.get_backend") twice, you will get the same IBMBackend instance, and any previously updated options will be reset to the default values.

It is also possible to use the `backend` attribute to reference a backend. As an example, to retrieve the same backend from the example above:

```python
Expand Down
109 changes: 0 additions & 109 deletions docs/api/qiskit-ibm-provider/qiskit_ibm_provider.Session.md

This file was deleted.

Loading

0 comments on commit f542c76

Please sign in to comment.