-
Notifications
You must be signed in to change notification settings - Fork 603
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
[WIP] Shot-allocation through sampling for split_non_commuting
#5832
base: master
Are you sure you want to change the base?
Conversation
Hello. You may have forgotten to update the changelog!
|
) | ||
|
||
shots_list = [ | ||
binom(n=rmng_shots, p=prob).rvs() for rmng_shots in remaining_shots_budget[idx] |
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.
Are we certain the values we put in here are always bounded between 0 and 1 (including numerical precision errors)?
@@ -28,10 +31,22 @@ | |||
from pennylane.typing import Result, ResultBatch | |||
|
|||
|
|||
class ObsMetadata(NamedTuple): |
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.
Any advantage of using a NamedTuple
vs a dataclass here?
@transform | ||
def split_non_commuting( | ||
tape: qml.tape.QuantumScript, | ||
grouping_strategy: Optional[str] = "default", | ||
term_sampling: Optional[Literal["weighted", "uniform"]] = None, |
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.
Please can this term be included in the docs
… bug in post-processing function
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #5832 +/- ##
==========================================
- Coverage 99.67% 99.66% -0.02%
==========================================
Files 432 432
Lines 41839 41607 -232
==========================================
- Hits 41702 41466 -236
- Misses 137 141 +4 ☔ View full report in Codecov by Sentry. |
Also @Shiro-Raven, please could you link the Shortcut story? |
Context:
Description of the Change:
Benefits:
Possible Drawbacks:
Related GitHub Issues:
[sc-64031]