Skip to main contentIBM Quantum Documentation
Important

IBM Quantum Platform is moving and this version will be sunset on July 1. To get started on the new platform, read the migration guide.

SamplerOptions

class SamplerOptions(_VERSION=2, max_execution_time=Unset, environment=<factory>, simulator=<factory>, default_shots=Unset, dynamical_decoupling=<factory>, execution=<factory>, twirling=<factory>, experimental=Unset)

GitHub

Bases: OptionsV2

Options for V2 Sampler.


Attributes

Parameters

default_shots

Type: UnsetType | int

Default value: Unset

The default number of shots to use if none are specified in the PUBs or in the run method.

Default: 4096.

dynamical_decoupling

Type: DynamicalDecouplingOptions | Dict

Default value: FieldInfo(annotation=Union[DynamicalDecouplingOptions, Dict], required=False, default_factory=DynamicalDecouplingOptions)

Suboptions for dynamical decoupling. See DynamicalDecouplingOptions for all available options.

environment

Type: EnvironmentOptions | Dict

Default value: FieldInfo(annotation=Union[EnvironmentOptions, Dict], required=False, default_factory=EnvironmentOptions)

execution

Type: SamplerExecutionOptionsV2 | Dict

Default value: FieldInfo(annotation=Union[SamplerExecutionOptionsV2, Dict], required=False, default_factory=SamplerExecutionOptionsV2)

Execution time options. See SamplerExecutionOptionsV2 for all available options.

experimental

Type: UnsetType | dict

Default value: Unset

Experimental options.

max_execution_time

Type: UnsetType | int

Default value: Unset

simulator

Type: SimulatorOptions | Dict

Default value: FieldInfo(annotation=Union[SimulatorOptions, Dict], required=False, default_factory=SimulatorOptions)

twirling

Type: TwirlingOptions | Dict

Default value: FieldInfo(annotation=Union[TwirlingOptions, Dict], required=False, default_factory=TwirlingOptions)

Pauli twirling options. See TwirlingOptions for all available options.


Methods

update

update(**kwargs)

GitHub

Update the options.

Parameters

kwargs (Any)

Return type

None

Was this page helpful?
Report a bug or request content on GitHub.