---
title: Specify Executor options
description: Specify options when building with the Executor primitive.
source: https://quantum.cloud.ibm.com/docs/en/guides/executor-options
---

# Specify Executor options

### Package versions

The code on this page was developed using the following requirements.
We recommend using these versions or newer.

```
qiskit-ibm-runtime~=0.46.1
```

You can use options to customize the Executor primitive. Unlike Sampler and Estimator, Executor has very few options since the majority of the design intents is encoded in the samplex.

> **Notes**
>
> - You can see the available options and update option values during or after primitive initialization.
> - Use the `update()` method to apply changes to the `options` attribute.
> - The `options` attribute is the `dataclass` Python type.  You can use the built-in `asdict` method to convert it to a dictionary.
> - Executor can only process information encoded in samplexes. Refer to the [Samplomatic guides](https://qiskit.github.io/samplomatic/guides/index) to understand restrictions.

## Set Executor options

If an option is specified both during and after primitive initialization, the value set after initializing the primitive is used.

### Primitive initialization

You can pass in an instance of the options class or a dictionary when initializing Executor, which then makes a copy of those options. Thus, changing the original dictionary or options instance doesn't affect the options owned by the primitive.

#### Options class

When creating an instance of the `Executor` class, you can pass in an instance of the options class. Those options are then applied when you use `run()` to perform the calculation.  Specify the options in this format:  `options.option.sub-option.sub-sub-option = choice`.  For example: `options.environment.log_level = INFO`.

Example:

```python
from qiskit_ibm_runtime import QiskitRuntimeService, Executor
from qiskit_ibm_runtime.options import ExecutorOptions

service = QiskitRuntimeService()
backend = service.least_busy(operational=True, simulator=False)

options = ExecutorOptions(
    environment={"log_level": "INFO"},
    execution={"init_qubits": True},
)

# or use the following instead:

options = ExecutorOptions()
options.environment.log_level = "INFO"
options.execution.init_qubits = True

executor = Executor(mode=backend, options=options)
```

#### Dictionary

You can specify options as a dictionary when initializing Executor.

```python
from qiskit_ibm_runtime import QiskitRuntimeService, Executor

service = QiskitRuntimeService()
backend = service.least_busy(operational=True, simulator=False)

# Setting options during primitive initialization
executor = Executor(
    backend,
    options={
        "environment": {"log_level": "INFO"},
        "execution": {"init_qubits": True},
    },
)
```

## Available options

The following table documents options from the latest version of `qiskit-ibm-runtime`. To see older option versions, visit the [`qiskit-ibm-runtime` API reference](/docs/api/qiskit-ibm-runtime) and select a previous version.

### \`environment\`

[`environment` API documentation](/docs/api/qiskit-ibm-runtime/options-sampler-options#environment)

### \`environment.job\_tags\`

List of tags.

**Choices**: None

**Default**: None

### \`environment.log\_level\`

**Choices**: DEBUG, INFO, WARNING, ERROR, CRITICAL

**Default**: WARNING

### \`environment.private\`

**Choices**: `True`, `False`

**Default**: `False`

### \`environment.max\_execution\_time\`

**Choices**: Integer number of seconds in the range \[1, 10800]

**Default**: 10800 (3 hours)

### \`execution\`

[`execution` API documentation](/docs/api/qiskit-ibm-runtime/options-sampler-options#execution)

### \`execution.init\_qubits\`

Whether to reset the qubits to the ground state for each shot.

**Choices**: `True`, `False`

**Default**: `True`

### \`execution.rep\_delay\`

The delay between a measurement and the subsequent quantum circuit.

**Choices**: Value in the range supplied by `backend.rep_delay_range`

**Default**: Given by `backend.default_rep_delay`

### \`execution.meas\_type\`

**Choices**: `classified`, `kerneled`, `avg_kerneled`

**Default**: `classified`

### \`experimental\`

Experimental options, when available.

## Next steps

> **Recommendations**
>
> - Review the [ExecutionOptionsV2](/docs/api/qiskit-ibm-runtime/options-execution-options-v2) API documentation.
> - Review the [EnvironmentOptions](/docs/api/qiskit-ibm-runtime/options-environment-options) API documentation.
