-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Add get config functions #7565
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
base: main
Are you sure you want to change the base?
Add get config functions #7565
Conversation
…ssor-config' into add_get_config_snapshot
I'm working on fixing the errors. Some missing tests/logic for a few edge cases. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #7565 +/- ##
========================================
Coverage 97.50% 97.51%
========================================
Files 1103 1105 +2
Lines 99652 99984 +332
========================================
+ Hits 97166 97496 +330
- Misses 2486 2488 +2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
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.
Remove
) -> processor_config.ProcessorConfig | None: | ||
"""Returns a ProcessorConfig from this project and the given processor id. | ||
|
||
If no run_name is provided, the config from the most recent run is returned. |
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.
I think you can remove this line now that we have the default argument for run_name
, or mention something about how we will use an internally-configured default run if left unspecified. Here and in the overrides.
) -> processor_config.ProcessorConfig | None: | ||
"""Returns a ProcessorConfig from this project and the given processor id. | ||
|
||
If no run_name is provided, the config from the most recent run is returned. |
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.
Update to talk about the default args
) -> processor_config.ProcessorConfig | None: | ||
"""Retrieves a ProcessorConfig from an automation run. | ||
|
||
If no run name is provided, the config from the most recent 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.
Update to mention default args
I've verified that this works fully end-to-end with a colab containing the following code:
|
Adds the ability to retrieve a
QuantumProcessorConfig
from a project. There are two ways to retrieve processor configs: from theEngine
or anEngineProcessor
.Here is an example using the processor:
Here is an example getting the config directly from the Engine: