---
title: PostSelectionOptions (latest version)
description: API reference for qiskit_ibm_runtime.options_models.PostSelectionOptions in the latest version of qiskit-ibm-runtime
source: https://eu-de.quantum.cloud.ibm.com/docs/en/api/qiskit-ibm-runtime/options-models-post-selection-options
---

# qiskit\_ibm\_runtime.options\_models.PostSelectionOptions

*pydantic model* `PostSelectionOptions`

[GitHub](https://github.com/Qiskit/qiskit-ibm-runtime/tree/stable/0.49/qiskit_ibm_runtime/options_models/post_selection.py#L35-L69)

Bases: `BaseOptionsModel`

Options for post selecting results.

**Config**

- **validate\_assignment**: *bool = True*
- **extra**: *str = forbid*

### enable

*field*

Type: `Annotated`\[`bool`, `AfterValidator`(`func``=``_warn_post_selection`)]

Default value: `False`

Whether to enable Post Selection when performing learning experiments.

If `True`, Post Selection is applied to all the learning circuits. In particular, the following steps are undertaken:

- **Using the passes in**

  `qiskit_addon_utils.noise_management.post_selection.transpiler.passes`, the learning circuits are modified by adding measurements on the spectator qubits, as well as post selection measurements.

- **The results of each individual learning circuits are post selected by discarding the shots**

  where one or more bits failed to flip, as explained in the docstring of `qiskit_addon_utils.noise_management.post_selection.PostSelector.compute_mask()`.

If `False`, all the other Post Selection options will be ignored.

**Constraints**

- **func** = \<function \_warn\_post\_selection at 0x7f3431e82170>

### strategy

*field*

Type: `Literal`\[`'node'`, `'edge'`]

Default value: `'node'`

The strategy used to decide if a shot should be kept or discarded.

The available startegies are:

- `'node'`: Discard every shot where one or more bits failed to flip. Keep every other shot.

- **`'edge'`: Discard every shot where there exists a pair of neighbouring qubits for which**

  both of the bits failed to flip. Keep every other shot.

See the dosctrings of `PostSelector` and `PostSelector.compute_mask()` for more details.

### x\_pulse\_type

*field*

Type: `Literal`\[`'xslow'`, `'rx'`]

Default value: `'xslow'`

The type of the X-pulse used for the post selection measurements.

### update

`update(**kwargs)`

[GitHub](https://github.com/Qiskit/qiskit-ibm-runtime/tree/stable/0.49/qiskit_ibm_runtime/options_models/base.py#L46-L54)

Update the options.

**Parameters**

**kwargs** (*Any*)

**Return type**

None
