Skip to content

Commit

Permalink
Update Runtime API docs to 0.13 (Qiskit#222)
Browse files Browse the repository at this point in the history
Now that we fixed Qiskit#67, we
can regenerate the API docs. The issues were due to changes with modern
Sphinx 7.2.

There was one regression I noticed, but it's not enough of a
show-stopper to block this PR:
Qiskit#224.
  • Loading branch information
Eric-Arellano authored Oct 24, 2023
1 parent 66a63f4 commit 2fdcc70
Show file tree
Hide file tree
Showing 20 changed files with 396 additions and 647 deletions.
2 changes: 1 addition & 1 deletion docs/api/qiskit-ibm-runtime/_toc.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"title": "Qiskit Runtime IBM Client",
"subtitle": "v0.11.3",
"subtitle": "v0.13.0",
"children": [
{
"title": "qiskit_ibm_runtime",
Expand Down
18 changes: 9 additions & 9 deletions docs/api/qiskit-ibm-runtime/options.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ python_api_type: module
python_api_name: qiskit_ibm_runtime.options
---

<span id="module-qiskit_ibm_runtime.options" />

<span id="primitive-options-qiskit-ibm-runtime-options" />

<span id="module-qiskit_ibm_runtime.options" />

# Primitive options

<span id="module-qiskit_ibm_runtime.options" />
Expand All @@ -18,7 +18,7 @@ python_api_name: qiskit_ibm_runtime.options

Options that can be passed to the primitives.

The [`Options`](qiskit_ibm_runtime.options.Options "qiskit_ibm_runtime.options.Options") class encapsulates all the options you can specify when invoking a primitive. It includes frequestly used options, such as `optimization_level` and `resilience_level` as well as sub-categories, such as `transpilation` and `execution`. You can use auto-complete to easily find the options inside each sub-category, for example:
The [`Options`](qiskit_ibm_runtime.options.Options "qiskit_ibm_runtime.options.Options") class encapsulates all the options you can specify when invoking a primitive. It includes frequently used options, such as `optimization_level` and `resilience_level` as well as sub-categories, such as `transpilation` and `execution`. You can use auto-complete to easily find the options inside each sub-category, for example:

```python
from qiskit_ibm_runtime.options import Options
Expand All @@ -39,10 +39,10 @@ options = Options(transpilation={"initial_layout": [0, 1, 2, 3]})

| | |
| -------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------- |
| [`Options`](qiskit_ibm_runtime.options.Options "qiskit_ibm_runtime.options.Options")(\[optimization\_level, ...]) | Options for the primitives. |
| [`TranspilationOptions`](qiskit_ibm_runtime.options.TranspilationOptions "qiskit_ibm_runtime.options.TranspilationOptions")(\[skip\_transpilation, ...]) | Transpilation options. |
| [`ResilienceOptions`](qiskit_ibm_runtime.options.ResilienceOptions "qiskit_ibm_runtime.options.ResilienceOptions")(\[noise\_amplifier, ...]) | Resilience options. |
| [`ExecutionOptions`](qiskit_ibm_runtime.options.ExecutionOptions "qiskit_ibm_runtime.options.ExecutionOptions")(\[shots, init\_qubits]) | Execution options. |
| [`EnvironmentOptions`](qiskit_ibm_runtime.options.EnvironmentOptions "qiskit_ibm_runtime.options.EnvironmentOptions")(\[log\_level, callback, ...]) | Options related to the execution environment. |
| [`SimulatorOptions`](qiskit_ibm_runtime.options.SimulatorOptions "qiskit_ibm_runtime.options.SimulatorOptions")(\[noise\_model, ...]) | Simulator options. |
| [`Options`](qiskit_ibm_runtime.options.Options "qiskit_ibm_runtime.options.Options")(\[optimization\_level, ...]) | Options for the primitives. |
| [`TranspilationOptions`](qiskit_ibm_runtime.options.TranspilationOptions "qiskit_ibm_runtime.options.TranspilationOptions")(\[skip\_transpilation, ...]) | Transpilation options. |
| [`ResilienceOptions`](qiskit_ibm_runtime.options.ResilienceOptions "qiskit_ibm_runtime.options.ResilienceOptions")(\[noise\_amplifier, ...]) | Resilience options. |
| [`ExecutionOptions`](qiskit_ibm_runtime.options.ExecutionOptions "qiskit_ibm_runtime.options.ExecutionOptions")(\[shots, init\_qubits]) | Execution options. |
| [`EnvironmentOptions`](qiskit_ibm_runtime.options.EnvironmentOptions "qiskit_ibm_runtime.options.EnvironmentOptions")(\[log\_level, callback, ...]) | Options related to the execution environment. |
| [`SimulatorOptions`](qiskit_ibm_runtime.options.SimulatorOptions "qiskit_ibm_runtime.options.SimulatorOptions")(\[noise\_model, ...]) | Simulator options. |

43 changes: 8 additions & 35 deletions docs/api/qiskit-ibm-runtime/qiskit_ibm_runtime.Estimator.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Class for interacting with Qiskit Runtime Estimator primitive service.

Qiskit Runtime Estimator primitive service estimates expectation values of quantum circuits and observables.

The [`run()`](qiskit_ibm_runtime.Estimator#run "qiskit_ibm_runtime.Estimator.run") can be used to submit circuits, observables, and parameters to the Estimator primitive.
The [`run()`](#qiskit_ibm_runtime.Estimator.run "qiskit_ibm_runtime.Estimator.run") can be used to submit circuits, observables, and parameters to the Estimator primitive.

You are encouraged to use [`Session`](qiskit_ibm_runtime.Session "qiskit_ibm_runtime.Session") to open a session, during which you can invoke one or more primitives. Jobs submitted within a session are prioritized by the scheduler, and data is cached for efficiency.

Expand Down Expand Up @@ -52,9 +52,6 @@ with Session(service=service, backend="ibmq_qasm_simulator") as session:
parameter_values=[theta1]*2
)
print(psi1_H23.result())
# Close the session only if all jobs are finished
# and you don't need to run more in the session
session.close()
```

Initializes the Estimator primitive.
Expand All @@ -73,13 +70,9 @@ Initializes the Estimator primitive.

## Attributes

<span id="estimator-circuits" />

### circuits

<span id="qiskit_ibm_runtime.Estimator.circuits" />

`tuple[qiskit.circuit.quantumcircuit.QuantumCircuit, ...]`
### circuits

Quantum circuits that represents quantum states.

Expand All @@ -91,13 +84,9 @@ Quantum circuits that represents quantum states.

The quantum circuits.

<span id="estimator-observables" />

### observables

<span id="qiskit_ibm_runtime.Estimator.observables" />

`tuple[qiskit.quantum_info.operators.symplectic.sparse_pauli_op.SparsePauliOp, ...]`
### observables

Observables to be estimated.

Expand All @@ -109,13 +98,9 @@ Observables to be estimated.

The observables.

<span id="estimator-options" />

### options

<span id="qiskit_ibm_runtime.Estimator.options" />

`Options`
### options

Return options values for the sampler.

Expand All @@ -127,13 +112,9 @@ Return options values for the sampler.

options

<span id="estimator-parameters" />

### parameters

<span id="qiskit_ibm_runtime.Estimator.parameters" />

`tuple[qiskit.circuit.parametertable.ParameterView, ...]`
### parameters

Parameters of the quantum circuits.

Expand All @@ -145,13 +126,9 @@ Parameters of the quantum circuits.

Parameters, where `parameters[i][j]` is the j-th parameter of the i-th circuit.

<span id="estimator-session" />

### session

<span id="qiskit_ibm_runtime.Estimator.session" />

`Session | None`
### session

Return session used by this primitive.

Expand All @@ -165,13 +142,11 @@ Session used by this primitive, or `None` if session is not used.

## Methods

<span id="estimator-run" />

### run

<span id="qiskit_ibm_runtime.Estimator.run" />

`Estimator.run(circuits, observables, parameter_values=None, **kwargs)`
`run(circuits, observables, parameter_values=None, **kwargs)`

Submit a request to the estimator primitive.

Expand All @@ -194,13 +169,11 @@ Submitted job. The result of the job is an instance of `qiskit.primitives.Estima

**ValueError** – Invalid arguments are given.

<span id="estimator-set-options" />

### set\_options

<span id="qiskit_ibm_runtime.Estimator.set_options" />

`Estimator.set_options(**fields)`
`set_options(**fields)`

Set options values for the sampler.

Expand Down
Loading

0 comments on commit 2fdcc70

Please sign in to comment.