Skip to content

Engine creator helper function#5658

Merged
CirqBot merged 11 commits intoquantumlib:masterfrom
augustehirth:get_sim_engine
Jul 7, 2022
Merged

Engine creator helper function#5658
CirqBot merged 11 commits intoquantumlib:masterfrom
augustehirth:get_sim_engine

Conversation

@augustehirth
Copy link
Copy Markdown
Collaborator

Add a helper function to create a virtual engine with a noisy simulator.

@augustehirth augustehirth requested review from a team, cduck, verult, vtomole and wcourtney as code owners June 30, 2022 22:10
@CirqBot CirqBot added the size: M 50< lines changed <250 label Jun 30, 2022
Comment thread cirq-google/cirq_google/engine/virtual_engine_factory.py Outdated
Comment thread cirq-google/cirq_google/engine/virtual_engine_factory.py Outdated
Comment thread cirq-google/cirq_google/engine/virtual_engine_factory.py Outdated
Comment thread cirq-google/cirq_google/engine/virtual_engine_factory_test.py Outdated
@dstrain115
Copy link
Copy Markdown
Collaborator

Are you going to expose this in the init files as well so that you don't have to specify the whole package?

@augustehirth augustehirth requested a review from dstrain115 June 30, 2022 23:07
@augustehirth
Copy link
Copy Markdown
Collaborator Author

Great points, ty. I think everything's fixed..

Comment thread cirq-google/cirq_google/engine/virtual_engine_factory.py Outdated
@mpharrigan
Copy link
Copy Markdown
Collaborator

API looks nice to me. This could be a good candidate for wrapping in a cg.workflow.SimulatedProcessorRecord subclass as a follow-up.

@augustehirth
Copy link
Copy Markdown
Collaborator Author

@mpharrigan The CI checks are onto the trickery. How to best evade this?

@mpharrigan
Copy link
Copy Markdown
Collaborator

all the test failures are about qiskit??? seems unrelated

for coverage: you can add

# coverage: ignore

to the block (may have to try exactly where to put it. test with check/pytest-changed-files-and-incremental-coverage

@mpharrigan
Copy link
Copy Markdown
Collaborator

mpharrigan commented Jul 1, 2022

for the typecheck you can add it to the list of ignored 3rd party modules in mypy.ini

edit: or add a type: ignore comment to that line

@augustehirth augustehirth requested a review from mpharrigan July 1, 2022 18:57
@mpharrigan
Copy link
Copy Markdown
Collaborator

@dstrain115 does this LGTY?

Copy link
Copy Markdown
Collaborator

@dstrain115 dstrain115 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, looks fine to me.

@augustehirth augustehirth added the automerge Tells CirqBot to sync and merge this PR. (If it's running.) label Jul 7, 2022
@CirqBot CirqBot added the front_of_queue_automerge CirqBot uses this label to indicate (and remember) what's being merged next. label Jul 7, 2022
@CirqBot CirqBot merged commit de3907c into quantumlib:master Jul 7, 2022
@CirqBot CirqBot removed automerge Tells CirqBot to sync and merge this PR. (If it's running.) front_of_queue_automerge CirqBot uses this label to indicate (and remember) what's being merged next. labels Jul 7, 2022
@augustehirth augustehirth deleted the get_sim_engine branch July 7, 2022 00:27
rht pushed a commit to rht/Cirq that referenced this pull request May 1, 2023
Add a helper function to create a virtual engine with a noisy simulator.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size: M 50< lines changed <250

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants