Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecate QuantumEngineSampler #5371

Closed
mpharrigan opened this issue May 16, 2022 · 0 comments · Fixed by #5432
Closed

Deprecate QuantumEngineSampler #5371

mpharrigan opened this issue May 16, 2022 · 0 comments · Fixed by #5432
Assignees
Labels
area/samplers kind/design-issue A conversation around design

Comments

@mpharrigan
Copy link
Collaborator

After much hand-wringing on #5361, I think we all have always agreed that QuantumEngineSampler needs to go.

  • Deprecate this class in favor of ProcessorSampler.
    • remove without replacement: sampler interface that can send to one of many processor ids
    • remove without replacement: sampler interface that can accept cg.EngineProgram
    • keep if you really want to: use Engine.run() if you want to send to one of many processor ids
  • Change cg.get_engine_sampler() and Engine.get_sampler() to delegate to Engine.get_processor(processor_id).get_sampler()
  • There's a weird place in the cg.calibration tools that dispatches on QuantumEngineSampler to get an engine instance to call the run_calibrations method. Need to figure out what to do here. Likely: check if ProcessorSampler.processor.engine is not None or get rid of this option all together.
@mpharrigan mpharrigan added the kind/design-issue A conversation around design label May 16, 2022
@dstrain115 dstrain115 self-assigned this May 25, 2022
dstrain115 added a commit to dstrain115/Cirq-1 that referenced this issue Jun 2, 2022
- Deprecates this class in favor of ProcessorSampler
- Moves get_engine_sampler into engine with the other utility functions
- Change engine.get_sampler to only support a single processor and have
  it point to the processor's sampler.

Fixes: quantumlib#5371
dstrain115 added a commit that referenced this issue Jun 3, 2022
* Deprecate QuantumEngineSampler

- Deprecates this class in favor of ProcessorSampler
- Moves get_engine_sampler into engine with the other utility functions
- Change engine.get_sampler to only support a single processor and have
  it point to the processor's sampler.
- Fix calibration workflow to use ProcessorSampler

Fixes: #5371
rht pushed a commit to rht/Cirq that referenced this issue May 1, 2023
* Deprecate QuantumEngineSampler

- Deprecates this class in favor of ProcessorSampler
- Moves get_engine_sampler into engine with the other utility functions
- Change engine.get_sampler to only support a single processor and have
  it point to the processor's sampler.
- Fix calibration workflow to use ProcessorSampler

Fixes: quantumlib#5371
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/samplers kind/design-issue A conversation around design
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants