@@ -177,56 +177,108 @@ Alternatively, users can set the following environment variables directly.
177
177
export PASQAL_PROJECT_ID=<>
178
178
179
179
180
- Submission from Python
180
+ Submitting
181
181
`````````````````````````
182
+ .. tab :: Python
182
183
183
- The target to which quantum kernels are submitted
184
- can be controlled with the ``cudaq::set_target() `` function.
184
+ The target to which quantum kernels are submitted
185
+ can be controlled with the ``cudaq::set_target() `` function.
185
186
186
- .. code :: python
187
+ .. code :: python
187
188
188
- cudaq.set_target(' pasqal' )
189
+ cudaq.set_target(' pasqal' )
189
190
190
191
191
- This accepts an optional argument, ``machine ``, which is used in the cloud platform to
192
- select the corresponding Pasqal QPU or emulator to execute on.
193
- See the `Pasqal cloud portal <https://portal.pasqal.cloud/ >`__ for an up to date list.
194
- The default value is ``EMU_MPS `` which is an open-source tensor network emulator based on the
195
- Matrix Product State formalism running in Pasqal's cloud platform. You can see the
196
- documentation for the publicly accessible emulator `here <https://pasqal-io.github.io/emulators/latest/emu_mps/ >`__.
192
+ This accepts an optional argument, ``machine ``, which is used in the cloud platform to
193
+ select the corresponding Pasqal QPU or emulator to execute on.
194
+ See the `Pasqal cloud portal <https://portal.pasqal.cloud/ >`__ for an up to date list.
195
+ The default value is ``EMU_MPS `` which is an open-source tensor network emulator based on the
196
+ Matrix Product State formalism running in Pasqal's cloud platform. You can see the
197
+ documentation for the publicly accessible emulator `here <https://pasqal-io.github.io/emulators/latest/emu_mps/ >`__.
197
198
198
- To target the QPU use the FRESNEL machine name. Note that there are restrictions
199
- regarding the values of the pulses as well as the register layout. We invite you to
200
- consult our `documentation <https://docs.pasqal.com/cloud/fresnel-job >`__. Note that
201
- the CUDA-Q integration currently only works with `arbitrary layouts <https://docs.pasqal.com/cloud/fresnel-job/#arbitrary-layouts >`__
202
- which are implemented with automatic calibration for less than 30 qubits. For jobs
203
- larger than 30 qubits please use the `atom_sites ` to define the layout, and use the
204
- `atom_filling ` to select sites as filled or not filled in order to define the register.
199
+ To target the QPU use the FRESNEL machine name. Note that there are restrictions
200
+ regarding the values of the pulses as well as the register layout. We invite you to
201
+ consult our `documentation <https://docs.pasqal.com/cloud/fresnel-job >`__. Note that
202
+ the CUDA-Q integration currently only works with `arbitrary layouts <https://docs.pasqal.com/cloud/fresnel-job/#arbitrary-layouts >`__
203
+ which are implemented with automatic calibration for less than 30 qubits. For jobs
204
+ larger than 30 qubits please use the `atom_sites ` to define the layout, and use the
205
+ `atom_filling ` to select sites as filled or not filled in order to define the register.
205
206
206
- Due to the nature of the underlying hardware, this target only supports the
207
- ``evolve `` and ``evolve_async `` APIs.
208
- The `hamiltonian ` must be an `Operator ` of the type `RydbergHamiltonian `. The only
209
- other supported parameters are `schedule ` (mandatory) and `shots_count ` (optional).
207
+ Due to the nature of the underlying hardware, this target only supports the
208
+ ``evolve `` and ``evolve_async `` APIs.
209
+ The `hamiltonian ` must be an `Operator ` of the type `RydbergHamiltonian `. The only
210
+ other supported parameters are `schedule ` (mandatory) and `shots_count ` (optional).
210
211
211
- For example,
212
+ For example,
212
213
213
- .. code :: python
214
+ .. code :: python
215
+
216
+ evolution_result = evolve(RydbergHamiltonian(atom_sites = register,
217
+ amplitude = omega,
218
+ phase = phi,
219
+ delta_global = delta),
220
+ schedule = schedule)
221
+
222
+ The number of shots for a kernel execution can be set through the ``shots_count ``
223
+ argument to ``evolve `` or ``evolve_async ``. By default, the ``shots_count `` is
224
+ set to 100.
225
+
226
+ .. code :: python
227
+
228
+ cudaq.evolve(RydbergHamiltonian(... ), schedule = s, shots_count = 1000 )
229
+
230
+ To see a complete example for using Pasqal's backend, take a look at our :doc: `Python examples <../../examples/hardware_providers >`.
231
+
232
+ .. tab :: C++
214
233
215
- evolution_result = evolve(RydbergHamiltonian(atom_sites = register,
216
- amplitude = omega,
217
- phase = phi,
218
- delta_global = delta),
219
- schedule = schedule)
234
+ To target quantum kernel code for execution on Pasqal QPU or simulators,
235
+ pass the flag ``--target pasqal `` to the ``nvq++ `` compiler.
220
236
221
- The number of shots for a kernel execution can be set through the ``shots_count ``
222
- argument to ``evolve `` or ``evolve_async ``. By default, the ``shots_count `` is
223
- set to 100.
237
+ .. code :: bash
238
+
239
+ nvq++ --target pasqal src.cpp
240
+
241
+ You can also pass the flag ``--pasqal-machine `` to select the corresponding Pasqal QPU or emulator to execute on.
242
+ See the `Pasqal cloud portal <https://portal.pasqal.cloud/ >`__ for an up to date list.
243
+ The default value is ``EMU_MPS `` which is an open-source tensor network emulator based on the
244
+ Matrix Product State formalism running in Pasqal's cloud platform. You can see the
245
+ documentation for the publicly accessible emulator `here <https://pasqal-io.github.io/emulators/latest/emu_mps/ >`__.
246
+
247
+ .. code :: bash
248
+
249
+ nvq++ --target pasqal --pasqal-machine EMU_FREE src.cpp
250
+
251
+ To target the QPU use the FRESNEL machine name. Note that there are restrictions
252
+ regarding the values of the pulses as well as the register layout. We invite you to
253
+ consult our `documentation <https://docs.pasqal.com/cloud/fresnel-job >`__. Note that
254
+ the CUDA-Q integration currently only works with `arbitrary layouts <https://docs.pasqal.com/cloud/fresnel-job/#arbitrary-layouts >`__
255
+ which are implemented with automatic calibration for less than 30 qubits. For jobs
256
+ larger than 30 qubits please use the `atom_sites ` to define the layout, and use the
257
+ `atom_filling ` to select sites as filled or not filled in order to define the register.
258
+
259
+ Due to the nature of the underlying hardware, this target only supports the
260
+ ``evolve `` and ``evolve_async `` APIs.
261
+ The `hamiltonian ` must be of the type `rydberg_hamiltonian `. Only
262
+ other parameters supported are `schedule ` (mandatory) and `shots_count ` (optional).
263
+
264
+ For example,
224
265
225
- .. code :: python
266
+ .. code :: cpp
226
267
227
- cudaq.evolve(RydbergHamiltonian(... ), schedule = s, shots_count = 1000 )
268
+ auto evolution_result = cudaq::evolve(
269
+ cudaq::rydberg_hamiltonian(register_sites, omega, phi, delta),
270
+ schedule);
271
+
272
+ The number of shots for a kernel execution can be set through the ``shots_count ``
273
+ argument to ``evolve `` or ``evolve_async ``. By default, the ``shots_count `` is
274
+ set to 100.
275
+
276
+ .. code :: cpp
277
+
278
+ auto evolution_result = cudaq::evolve(cudaq::rydberg_hamiltonian(...), schedule, 1000);
279
+
280
+ To see a complete example for using Pasqal's backend, take a look at our :doc: `C++ examples <../../examples/hardware_providers >`.
228
281
229
- To see a complete example for using Pasqal's backend, take a look at our :doc: `Python examples <../../examples/hardware_providers >`.
230
282
231
283
.. note ::
232
284
@@ -261,47 +313,81 @@ Alternatively, users can set the following environment variables.
261
313
export AWS_SECRET_ACCESS_KEY=" <access_key>"
262
314
export AWS_SESSION_TOKEN=" <token>"
263
315
264
- Submission from Python
316
+ About Aquila
265
317
`````````````````````````
266
318
267
- The target to which quantum kernels are submitted
268
- can be controlled with the ``cudaq::set_target() `` function.
269
-
270
- .. code :: python
271
-
272
- cudaq.set_target(' quera' )
273
-
274
- By default, analog Hamiltonian will be submitted to the Aquila system.
275
-
276
319
Aquila is a "field programmable qubit array" operated as an analog
277
320
Hamiltonian simulator on a user-configurable architecture, executing
278
321
programmable coherent quantum dynamics on up to 256 neutral-atom qubits.
279
322
Refer to QuEra's `whitepaper <https://cdn.prod.website-files.com/643b94c382e84463a9e52264/648f5bf4d19795aaf36204f7_Whitepaper%20June%2023.pdf >`__ for details.
280
323
281
- Due to the nature of the underlying hardware, this target only supports the
282
- ``evolve `` and ``evolve_async `` APIs.
283
- The `hamiltonian ` must be an `Operator ` of the type `RydbergHamiltonian `. Only
284
- other parameters supported are `schedule ` (mandatory) and `shots_count ` (optional).
324
+ Submitting
325
+ `````````````````````````
326
+ .. tab :: Python
327
+
328
+ The target to which quantum kernels are submitted
329
+ can be controlled with the ``cudaq::set_target() `` function.
330
+
331
+ .. code :: python
285
332
286
- For example,
333
+ cudaq.set_target( ' quera ' )
287
334
288
- .. code :: python
335
+ Due to the nature of the underlying hardware, this target only supports the
336
+ ``evolve `` and ``evolve_async `` APIs.
337
+ The `hamiltonian ` must be an `Operator ` of the type `RydbergHamiltonian `. Only
338
+ other parameters supported are `schedule ` (mandatory) and `shots_count ` (optional).
339
+
340
+ For example,
341
+
342
+ .. code :: python
343
+
344
+ evolution_result = evolve(RydbergHamiltonian(atom_sites = register,
345
+ amplitude = omega,
346
+ phase = phi,
347
+ delta_global = delta),
348
+ schedule = schedule)
349
+
350
+ The number of shots for a kernel execution can be set through the ``shots_count ``
351
+ argument to ``evolve `` or ``evolve_async ``. By default, the ``shots_count `` is
352
+ set to 100.
353
+
354
+ .. code :: python
355
+
356
+ cudaq.evolve(RydbergHamiltonian(... ), schedule = s, shots_count = 1000 )
357
+
358
+ To see a complete example for using QuEra's backend, take a look at our :doc: `Python examples <../../examples/hardware_providers >`.
359
+
360
+ .. tab :: C++
361
+
362
+ To target quantum kernel code for execution on QuEra's Aquila,
363
+ pass the flag ``--target quera `` to the ``nvq++ `` compiler.
364
+
365
+ .. code :: bash
366
+
367
+ nvq++ --target quera src.cpp
368
+
369
+ Due to the nature of the underlying hardware, this target only supports the
370
+ ``evolve `` and ``evolve_async `` APIs.
371
+ The `hamiltonian ` must be of the type `rydberg_hamiltonian `. Only
372
+ other parameters supported are `schedule ` (mandatory) and `shots_count ` (optional).
373
+
374
+ For example,
375
+
376
+ .. code :: cpp
289
377
290
- evolution_result = evolve(RydbergHamiltonian(atom_sites = register,
291
- amplitude = omega,
292
- phase = phi,
293
- delta_global = delta),
294
- schedule = schedule)
378
+ auto evolution_result = cudaq::evolve(
379
+ cudaq::rydberg_hamiltonian(register_sites, omega, phi, delta),
380
+ schedule);
295
381
296
- The number of shots for a kernel execution can be set through the ``shots_count ``
297
- argument to ``evolve `` or ``evolve_async ``. By default, the ``shots_count `` is
298
- set to 100.
382
+ The number of shots for a kernel execution can be set through the ``shots_count ``
383
+ argument to ``evolve `` or ``evolve_async ``. By default, the ``shots_count `` is
384
+ set to 100.
299
385
300
- .. code :: python
386
+ .. code :: cpp
301
387
302
- cudaq. evolve(RydbergHamiltonian (... ), schedule = s, shots_count = 1000 )
388
+ auto evolution_result = cudaq:: evolve(cudaq::rydberg_hamiltonian (...), schedule, 1000);
303
389
304
- To see a complete example for using QuEra's backend, take a look at our :doc: `Python examples <../../examples/hardware_providers >`.
390
+ To see a complete example for using QuEra's backend, take a look at our :doc: `C++ examples <../../examples/hardware_providers >`.
305
391
306
392
.. note ::
307
393
0 commit comments