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

[cirqflow] Convenience method for loading results #4720

Merged
merged 5 commits into from
Dec 22, 2021

Conversation

mpharrigan
Copy link
Collaborator

Add cg.ExecutableGroupResultFilesystemRecord.from_json(run_id)

Add cg.ExecutableGroupResultFilesystemRecord.from_json(run_id)
@google-cla google-cla bot added the cla: yes Makes googlebot stop complaining. label Dec 2, 2021
@CirqBot CirqBot added the size: S 10< lines changed <50 label Dec 2, 2021
@mpharrigan
Copy link
Collaborator Author

@tanujkhattar do you have any comments on this before I flesh it out. Fixes #4732

Copy link
Collaborator

@tanujkhattar tanujkhattar left a comment

Choose a reason for hiding this comment

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

LGTM. Will approve once this ready for review.

Comment on lines +51 to +52
fn = f'{base_data_dir}/{run_id}/ExecutableGroupResultFilesystemRecord.json.gz'
egr_record = cirq.read_json_gzip(fn)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Nice, I didn't realize we were also storing ExecutableGroupResultFilesystemRecord and therefore we can fetch the runtime_configuration_path, shared_runtime_info_path etc. by directly reading this json instead of hardcoding any paths here.

@mpharrigan mpharrigan marked this pull request as ready for review December 21, 2021 16:01
@mpharrigan mpharrigan requested review from cduck, vtomole, wcourtney and a team as code owners December 21, 2021 16:01
@tanujkhattar tanujkhattar added the automerge Tells CirqBot to sync and merge this PR. (If it's running.) label Dec 22, 2021
@CirqBot CirqBot added the front_of_queue_automerge CirqBot uses this label to indicate (and remember) what's being merged next. label Dec 22, 2021
@CirqBot CirqBot merged commit 65d783e into quantumlib:master Dec 22, 2021
@CirqBot CirqBot removed automerge Tells CirqBot to sync and merge this PR. (If it's running.) front_of_queue_automerge CirqBot uses this label to indicate (and remember) what's being merged next. labels Dec 22, 2021
MichaelBroughton pushed a commit to MichaelBroughton/Cirq that referenced this pull request Jan 22, 2022
Add cg.ExecutableGroupResultFilesystemRecord.from_json(run_id)
rht pushed a commit to rht/Cirq that referenced this pull request May 1, 2023
Add cg.ExecutableGroupResultFilesystemRecord.from_json(run_id)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/workflow cla: yes Makes googlebot stop complaining. size: S 10< lines changed <50
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants