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

Updates to README to add poll_timeout_seconds #79

Merged
merged 3 commits into from
May 19, 2020

Conversation

randalld-aws
Copy link
Contributor

Issue #, if available:

Description of changes:
Update to README to include poll_timeout_seconds in the example to run an algorithm on a QPU.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

randalld-aws and others added 2 commits May 18, 2020 16:00
Updated the example algorithm to include poll_timeout_seconds, which lets you increase the default polling time to avoid local timeout errors when QPUs are not immediately available to run a task.
@randalld-aws randalld-aws requested a review from kshitijc May 18, 2020 23:43
@randalld-aws randalld-aws requested a review from avawang1 as a code owner May 18, 2020 23:43
README.md Outdated
@@ -254,7 +254,7 @@ Tasks sent to QPUs don't always run right away. For IonQ, jobs are run once ever
## Running a Quantum Algorithm on a Quantum Computer
With Amazon Braket, you can run your quantum circuit on a physical quantum computer. The steps to do so are the same as those described to validate your environment. Just replace the example code provided in this document with your own code.

The following example executes the same Bell Pair example described to validate your configuration against a Rigetti quantum computer.
The following example executes the same Bell Pair example described to validate your configuration against a Rigetti quantum computer. For the case when the specified QPU is unavailable and tasks are not immediately run, a `poll_timeout_seconds` parameter is included to set a longer polling time. With this parameter, the results are not returned until the task reaches a status of COMPLETE, FAILED, or CANCELLED, or 24 hours passes. When using the default polling time, local timeout errors occur in some cases while waiting for the QPU to process the task. This example sets the polling time to one day (24 hours). Since tasks typically run within 24 hours this keeps the local task from timing out before the task is run on the QPU.
Copy link
Contributor

Choose a reason for hiding this comment

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

"For the case when the specified QPU is unavailable and tasks are not immediately run, a poll_timeout_seconds parameter is included" -> Could this cause the users to think that there are specific cases they need to know about when the poll_timeout_seconds needs to be supplied ?

Would it be better to say that the simulator/QPUs might not return results immediately and we might need to poll for the results longer. This behavior can be tuned using the poll_timeout_seconds parameter. We poll for results until either the task finishes execution (which can either be successful or unsuccessful) or the poll timeout seconds period has elapsed. This example sets the polling time to one day .....

@randalld-aws randalld-aws merged commit 2e31bc5 into master May 19, 2020
@randalld-aws randalld-aws deleted the feature/docs_update branch May 19, 2020 00:39
@randalld-aws randalld-aws changed the title Feature/docs update Updates to README to add poll_timeout_seconds May 19, 2020
kshitijc pushed a commit that referenced this pull request May 19, 2020
* Update README example to use poll_timeout_seconds

Updated the example algorithm to include poll_timeout_seconds, which lets you increase the default polling time to avoid local timeout errors when QPUs are not immediately available to run a task.

* Update to README to correct the description for poll_timout

* Update README description of polling_timeout_seconds
kshitijc pushed a commit that referenced this pull request May 19, 2020
* Update README example to use poll_timeout_seconds

Updated the example algorithm to include poll_timeout_seconds, which lets you increase the default polling time to avoid local timeout errors when QPUs are not immediately available to run a task.

* Update to README to correct the description for poll_timout

* Update README description of polling_timeout_seconds
@randalld-aws randalld-aws restored the feature/docs_update branch May 20, 2020 18:49
@randalld-aws randalld-aws deleted the feature/docs_update branch May 20, 2020 19:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants