mqt.core.plugins.qiskit.sampler

Sampler implementation for QDMI backends.

Module Contents

class QDMISampler(backend: QDMIBackend, *, default_shots: int = 1024, options: dict[str, Any] | None = None)[source]

Bases: qiskit.primitives.base.BaseSamplerV2

QDMI implementation of Qiskit’s SamplerV2.

property backend: QDMIBackend

The backend used by the sampler.

run(pubs: Iterable[qiskit.primitives.containers.SamplerPubLike], *, shots: int | None = None) PrimitiveJob[qiskit.primitives.containers.PrimitiveResult[qiskit.primitives.containers.SamplerPubResult]][source]

Run and collect samples from each provided PUB.

Parameters:
  • pubs – An iterable of pub-like objects.

  • shots – The number of shots to sample. If None, the default is used.

Returns:

A job that will return the primitive result.