@@ -70,6 +70,35 @@ of the time. To minimize the duration of the circuit, it is best to align
70
70
gates of the same duration together when possible. See the
71
71
[ best practices] ( ./best_practices.ipynb ) for more details.
72
72
73
+ ## Device Parameter Sweeps
74
+
75
+ Certain device parameters can be changed for the duration of
76
+ a circuit in order to support hardware parameter sweeps. For instance,
77
+ frequencies, amplitudes, and various other parameters can be modified
78
+ in order to find optimal values or explore the parameter space.
79
+
80
+ These parameter names are generally not public, so you will need to
81
+ work with a Google sponsor or resident in order to access the proper
82
+ key names. These parameters are specified as lists of strings representing
83
+ a path from the device config's folder (or the "sample folder").`
84
+
85
+ These keys can be swept like any other symbol using the
86
+ ` cirq_google.study.DeviceParameter ` variable. For instance, the
87
+ following code will sweep qubit (4,8)'s pi amplitude from 0.0 to 1.0
88
+ in 0.02 increments.
89
+
90
+
91
+ ```
92
+ descriptor = cirq_google.study.DeviceParameter( ["q4_8", "piAmp"])
93
+ sweep = cirq.Linspace("q4_8.piAmp", 0,1,51, metadata = descriptor)
94
+ ```
95
+
96
+ Any ` DeviceParameter ` keys that are set to a single value using a ` cirq.Points `
97
+ object will change that value for all circuits run.
98
+
99
+ If units are required, they should be specified as a string (such as 'MHz')
100
+ using the ` units ` argument of the ` DeviceParameter ` .
101
+
73
102
## Gates supported
74
103
75
104
The following lists the gates supported by Google devices.
0 commit comments