-
Notifications
You must be signed in to change notification settings - Fork 28
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
Introduce Dynamic Definition function to the wire cutting modules. #285
Conversation
Pull Request Test Coverage Report for Build 5482095635
💛 - Coveralls |
This looks great, thanks! Looks like the linter is failing. You should be able to
from the root of the repo. You can also run |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Really nice work, and thanks again for porting this over. We have had this as a to-do for a while now :)
Most of my comments are just pedantic docstring cleanups and commented print statement cleanups.
If you could take a look at the linter (currently failing the black --check
) and also the two lines missing from coverage in the new code. If you can cover those two lines with a couple simple tests, we like to do that. If it's a pain to cover those lines for some reason, we can ignore them for coverage explicitly.
circuit_knitting/cutting/cutqc/wire_cutting_dynamic_definition.py
Outdated
Show resolved
Hide resolved
circuit_knitting/cutting/cutqc/wire_cutting_dynamic_definition.py
Outdated
Show resolved
Hide resolved
circuit_knitting/cutting/cutqc/wire_cutting_dynamic_definition.py
Outdated
Show resolved
Hide resolved
circuit_knitting/cutting/cutqc/wire_cutting_dynamic_definition.py
Outdated
Show resolved
Hide resolved
circuit_knitting/cutting/cutqc/wire_cutting_dynamic_definition.py
Outdated
Show resolved
Hide resolved
circuit_knitting/cutting/cutqc/wire_cutting_dynamic_definition.py
Outdated
Show resolved
Hide resolved
circuit_knitting/cutting/cutqc/wire_cutting_dynamic_definition.py
Outdated
Show resolved
Hide resolved
circuit_knitting/cutting/cutqc/wire_cutting_dynamic_definition.py
Outdated
Show resolved
Hide resolved
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Co-authored-by: Caleb Johnson <calebj1524@outlook.com>
Thank you for reviewing. I should have combined your suggestions with batch into one commit. Sorry for the dirty commit log😰 I added the test to achieve 100% coverage and executed lint programs. |
Hah! No worries at all! Thanks for the quick turnaround |
I'm going to give @garrison a chance to look at this, and I'm going to make another pass shortly, but it's looking great |
Please add the following line to the body of one of your commit messages, in order to acknowledge the original author of this code. (You could even create an empty commit, using
|
Co-authored-by: weiT1993 <tangwei1027@gmail.com>
I added the co-author and fix lint. |
Co-authored-by: Jim Garrison <jim@garrison.cc>
This PR deserves a release note, too. |
I updated |
Thank you again for this!! It will be in the v0.3 release, which we expect to tag shortly. 🎉 |
Thanks @hitomitak ! |
Sorry I was on summer vacation and could not respond. Thanks for the merge. |
Ported Dynamic Definition code to the wire cutting function and added its test. This function has the following features.
dd_bin
)reconstruct_dd_full_distribute
)The original code used a file to perform the merge process of each result but this PR changes to do it on memory.
The following code is the example of their use.