iqm.benchmarks.entanglement.graph_states.GraphStateConfiguration#
- class iqm.benchmarks.entanglement.graph_states.GraphStateConfiguration(*, benchmark: ~typing.Type[~iqm.benchmarks.benchmark_definition.Benchmark] = <class 'iqm.benchmarks.entanglement.graph_states.GraphStateBenchmark'>, shots: int = 256, max_gates_per_batch: int | None = None, max_circuits_per_batch: int | None = None, calset_id: str | None = None, routing_method: ~typing.Literal['basic', 'lookahead', 'stochastic', 'sabre', 'none'] = 'sabre', physical_layout: ~typing.Literal['fixed', 'batching'] = 'fixed', use_dd: bool | None = False, dd_strategy: ~iqm.iqm_client.models.DDStrategy | None = None, qubits: ~typing.Sequence[int], tomography: ~typing.Literal['state_tomography', 'shadow_tomography'] = 'state_tomography', num_bootstraps: int = 50, n_random_unitaries: int = 100, n_median_of_means: int = 1)#
Bases:
BenchmarkConfigurationBase
Graph States Benchmark configuration.
- Parameters:
shots (int) –
max_gates_per_batch (int | None) –
max_circuits_per_batch (int | None) –
calset_id (str | None) –
routing_method (Literal['basic', 'lookahead', 'stochastic', 'sabre', 'none']) –
physical_layout (Literal['fixed', 'batching']) –
use_dd (bool | None) –
dd_strategy (DDStrategy | None) –
tomography (Literal['state_tomography', 'shadow_tomography']) –
num_bootstraps (int) –
n_random_unitaries (int) –
n_median_of_means (int) –
- tomography#
Whether to use state or shadow tomography. * Default is “state_tomography”.
- Type:
Literal[“state_tomography”, “shadow_tomography”]
- num_bootstraps#
The amount of bootstrap samples to use with state tomography. * Default is 50.
- Type:
- n_random_unitaries#
The number of Haar random single-qubit unitaries to use for (local) shadow tomography. * Default is 100.
- Type:
- n_median_of_means#
The number of mean samples over n_random_unitaries to generate a median of means estimator for shadow tomography. * NB: The total amount of execution calls will be a multiplicative factor of n_random_unitaries x n_median_of_means. * Default is 1 (no median of means).
- Type:
Attributes
A dictionary of computed field names and their corresponding ComputedFieldInfo objects.
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
Metadata about the fields defined on the model, mapping of field names to [FieldInfo][pydantic.fields.FieldInfo] objects.
shots
max_gates_per_batch
max_circuits_per_batch
calset_id
routing_method
physical_layout
use_dd
dd_strategy
Methods
- model_computed_fields: ClassVar[Dict[str, ComputedFieldInfo]] = {}#
A dictionary of computed field names and their corresponding ComputedFieldInfo objects.
- model_config: ClassVar[ConfigDict] = {}#
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_fields: ClassVar[Dict[str, FieldInfo]] = {'benchmark': FieldInfo(annotation=Type[Benchmark], required=False, default=<class 'iqm.benchmarks.entanglement.graph_states.GraphStateBenchmark'>), 'calset_id': FieldInfo(annotation=Union[str, NoneType], required=False, default=None), 'dd_strategy': FieldInfo(annotation=Union[DDStrategy, NoneType], required=False, default=None), 'max_circuits_per_batch': FieldInfo(annotation=Union[int, NoneType], required=False, default=None), 'max_gates_per_batch': FieldInfo(annotation=Union[int, NoneType], required=False, default=None), 'n_median_of_means': FieldInfo(annotation=int, required=False, default=1), 'n_random_unitaries': FieldInfo(annotation=int, required=False, default=100), 'num_bootstraps': FieldInfo(annotation=int, required=False, default=50), 'physical_layout': FieldInfo(annotation=Literal['fixed', 'batching'], required=False, default='fixed'), 'qubits': FieldInfo(annotation=Sequence[int], required=True), 'routing_method': FieldInfo(annotation=Literal['basic', 'lookahead', 'stochastic', 'sabre', 'none'], required=False, default='sabre'), 'shots': FieldInfo(annotation=int, required=False, default=256), 'tomography': FieldInfo(annotation=Literal['state_tomography', 'shadow_tomography'], required=False, default='state_tomography'), 'use_dd': FieldInfo(annotation=Union[bool, NoneType], required=False, default=False)}#
Metadata about the fields defined on the model, mapping of field names to [FieldInfo][pydantic.fields.FieldInfo] objects.
This replaces Model.__fields__ from Pydantic V1.