Pulled out Cirq proto dependency. #590
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
People with L + 3 foresight (@dabacon, @balopat ) independently predicted we might run into issues with our dependency on the "pre-compiled never re-built" cirq
***_pb2.py
files as well as their associated serialization logic. Despite these predictions being over a year old, the first warning signs have come through here (quantumlib/Cirq#4161).This PR pulls out the original serialization logic we built on from Cirq v0.9.0 release tag (the one with the most minimal serialization that still supports everything we need) and moves it entirely into the TFQ repo. From here we can gradually trim off the things we don't need and cut down on proto size to get the code running even faster while removing our explicit proto version requirements as well as dependency on the pre-generated proto files. This will also make life for Cirq easier since they won't have to worry (as much) about proto issues and serialization logic downstream for us.