-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Treat Reset like Measure in ConstrainedReschedule #11756
Conversation
One or more of the the following people are requested to review this:
|
Pull Request Test Coverage Report for Build 8070375077Warning: This coverage report may be inaccurate.This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.
Details
💛 - Coveralls |
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.
Thanks @hunterkemeny for adding support for reset instruction. Since Qiskit is assumed to be vendor agnostic (I'm not sure if this can be true for low level operations like a scheduling), the warning message should be more generic. I added some suggestions but feel free to update if you have better wording.
Let me confirm your intention. As you may notice ConstrainedReschedule
is not a BaseScheduler
subclass where you added the user warnings. This means user will never see the message when they only run the rescheduler. In principle rescheduler doesn't work without scheduling, so you are expecting the user will see the message at first scheduling step, then no additional error will raise in rescheduler, right?
releasenotes/notes/add-scheduler-warnings-da6968a39fd8e6e7.yaml
Outdated
Show resolved
Hide resolved
Co-authored-by: Naoki Kanazawa <[email protected]>
Co-authored-by: Naoki Kanazawa <[email protected]>
Co-authored-by: Naoki Kanazawa <[email protected]>
… calibration if statement
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.
Thanks, this looks good to me.
Summary
fixes #10354 ConstrainedReschedule raises an error with reset
Details and comments
Reset and Measure (mid-circuit) both provide duration data from the backend, but this is untrustworthy. To reflect this, I added RuntimeWarnings in
qiskit/transpiler/passes/scheduling/base_scheduler.py
.That Reset reports duration data is not recognized in
ConstrainedReschedule
, leading to the error in Issue #10354. Thus, I added the same handling for Reset inConstrainedReschedule
as is used for Measure.