-
Notifications
You must be signed in to change notification settings - Fork 1.2k
cirq_google GridDevice: set JSON namespace to cirq.google #5512
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
cirq_google GridDevice: set JSON namespace to cirq.google #5512
Conversation
95-martin-orion
left a comment
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.
+1
| 'GoogleNoiseProperties': cirq_google.GoogleNoiseProperties, | ||
| 'SycamoreGate': cirq_google.SycamoreGate, | ||
| 'GateTabulation': cirq_google.GateTabulation, | ||
| 'GridDevice': cirq_google.GridDevice, |
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.
[No change needed] As discussed, this is safe because GridDevice has not yet appeared in a Cirq release.
|
Yes, using the json "namespacing" feature is much preferred to coming up with new names that don't match the class name. All objects would ideally be namespaced (with a carveout for top-level |
…#5512) Preferred alternative over quantumlib#5476 (renaming `GridDevice` to `GoogleGridDevice`). This resolves the issue of JSON name collisions between cirq_google and elsewhere by including the `cirq.google` namespace. Furthermore, by staying with `GridDevice` as the class name, we require the caller to include the `cirq-google` module name in cases when multiple `GridDevice` classes are used (for example in the server side code today). @95-martin-orion @mpharrigan cc @dstrain115 @tanujkhattar
…#5512) Preferred alternative over quantumlib#5476 (renaming `GridDevice` to `GoogleGridDevice`). This resolves the issue of JSON name collisions between cirq_google and elsewhere by including the `cirq.google` namespace. Furthermore, by staying with `GridDevice` as the class name, we require the caller to include the `cirq-google` module name in cases when multiple `GridDevice` classes are used (for example in the server side code today). @95-martin-orion @mpharrigan cc @dstrain115 @tanujkhattar
Preferred alternative over #5476 (renaming
GridDevicetoGoogleGridDevice). This resolves the issue of JSON name collisions between cirq_google and elsewhere by including thecirq.googlenamespace.Furthermore, by staying with
GridDeviceas the class name, we require the caller to include thecirq-googlemodule name in cases when multipleGridDeviceclasses are used (for example in the server side code today).@95-martin-orion @mpharrigan
cc @dstrain115 @tanujkhattar