Skip to content

Partial Support for tags in cirq_google protos#7044

Merged
dstrain115 merged 8 commits intoquantumlib:mainfrom
dstrain115:add_tags_to_proto2
Feb 11, 2025
Merged

Partial Support for tags in cirq_google protos#7044
dstrain115 merged 8 commits intoquantumlib:mainfrom
dstrain115:add_tags_to_proto2

Conversation

@dstrain115
Copy link
Copy Markdown
Collaborator

  • This adds several tags to cirq_google protos, and also adds partial support for serialization and deserialization of tags.

Note: still pending are arguments for InternalTag objects and better ability to serialize/deserialize internal tags that are not public.

- This adds several tags to cirq_google protos, and also adds
partial support for serialization and deserialization of tags.

Note: still pending are arguments for InternalTag objects and
better ability to serialize/deserialize internal tags that are
not public.
@dstrain115 dstrain115 requested review from a team, verult, vtomole and wcourtney as code owners February 7, 2025 23:01
@CirqBot CirqBot added the size: L 250< lines changed <1000 label Feb 7, 2025
Comment thread cirq-google/cirq_google/ops/dynamical_decoupling_tag.py
Comment thread cirq-google/cirq_google/ops/fsim_via_model_tag.py Outdated
Comment thread cirq-google/cirq_google/ops/internal_tag.py Outdated
msg = program_pb2.Tag()
msg.internal_tag.tag_name = self.name
msg.internal_tag.tag_package = self.package
# for k, v in self.tag_args.items():
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I guess this is left for a follow-up PR?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Yes, removed. Probably needs a refactor since it introduces a circular dependency.

Comment thread cirq-google/cirq_google/ops/physical_z_tag.py Outdated
Comment thread cirq-google/cirq_google/serialization/circuit_serializer.py Outdated
Comment thread cirq-google/cirq_google/serialization/circuit_serializer.py Outdated
@codecov
Copy link
Copy Markdown

codecov bot commented Feb 10, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.17%. Comparing base (7f46121) to head (ba6462a).
Report is 4 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff            @@
##             main    #7044    +/-   ##
========================================
  Coverage   98.17%   98.17%            
========================================
  Files        1087     1087            
  Lines       94724    94840   +116     
========================================
+ Hits        92993    93110   +117     
+ Misses       1731     1730     -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@dstrain115 dstrain115 added this pull request to the merge queue Feb 11, 2025
Merged via the queue into quantumlib:main with commit 1c55f3f Feb 11, 2025
@dstrain115 dstrain115 deleted the add_tags_to_proto2 branch February 11, 2025 18:03
BichengYing pushed a commit to BichengYing/Cirq that referenced this pull request Jun 20, 2025
* Partial Support for tags in cirq_google protos

- This adds several tags to cirq_google protos, and also adds
partial support for serialization and deserialization of tags.

Note: still pending are arguments for InternalTag objects and
better ability to serialize/deserialize internal tags that are
not public.

* Update cirq-google/cirq_google/ops/fsim_via_model_tag.py

Co-authored-by: Pavol Juhas <pavol.juhas@gmail.com>

* Update cirq-google/cirq_google/ops/physical_z_tag.py

Co-authored-by: Pavol Juhas <pavol.juhas@gmail.com>

* Update cirq-google/cirq_google/ops/internal_tag.py

Co-authored-by: Pavol Juhas <pavol.juhas@gmail.com>

* Update cirq-google/cirq_google/serialization/circuit_serializer.py

Co-authored-by: Pavol Juhas <pavol.juhas@gmail.com>

* Address some comments.

* Address other comment.

* Solve all the CI problems.

---------

Co-authored-by: Pavol Juhas <pavol.juhas@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size: L 250< lines changed <1000

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants