iqm-pulla 9.9.0__py3-none-any.whl → 10.1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -71,6 +71,7 @@ STANDARD_CIRCUIT_EXECUTION_OPTIONS_DICT = {
71
71
  "move_gate_frame_tracking": MoveGateFrameTrackingMode.FULL,
72
72
  "move_gate_validation": MoveGateValidationMode.STRICT,
73
73
  "active_reset_cycles": None,
74
+ "convert_terminal_measurements": True,
74
75
  }
75
76
 
76
77
  STANDARD_CIRCUIT_EXECUTION_OPTIONS = CircuitExecutionOptions(**STANDARD_CIRCUIT_EXECUTION_OPTIONS_DICT) # type: ignore
@@ -248,6 +248,7 @@ def _build_readout_mappings(
248
248
  builder: ScheduleBuilder,
249
249
  measurement_mode: MeasurementMode,
250
250
  heralding_mode: HeraldingMode,
251
+ convert_terminal_measurements: bool,
251
252
  ) -> tuple[tuple[ReadoutMapping, ...], tuple[tuple[str, ...], ...]]:
252
253
  """Create a readout mapping for each circuit, add required measurement instructions.
253
254
 
@@ -264,6 +265,8 @@ def _build_readout_mappings(
264
265
  builder: schedule builder object, encapsulating station properties and gate calibration data
265
266
  measurement_mode: measurement mode to be used
266
267
  heralding_mode: type of heralding used
268
+ convert_terminal_measurements: whether to convert terminal measurements into the ``"measure_fidelity"``
269
+ operation.
267
270
 
268
271
  Returns:
269
272
  readout mappings, heralded components
@@ -323,13 +326,21 @@ def _build_readout_mappings(
323
326
  final_measurements.append(inst)
324
327
  eclipsed_qubits.update(inst.locus)
325
328
 
329
+ if convert_terminal_measurements:
330
+ final_measurements_name = "measure_fidelity"
331
+ for measurement in final_measurements:
332
+ measurement.name = final_measurements_name
333
+ else:
334
+ final_measurements_name = "measure"
326
335
  # Add a single final measurement instruction for qubits that still need to be measured
327
336
  # (order does not matter). this measurement instruction is not reflected in circuit_metrics,
328
337
  # nor are the results returned by SC. NOTE we assume that iqm-pulse is clever enough to
329
338
  # combine the separate final measurement instructions into simultaneous ReadoutTriggers.
330
339
  if missing := final_components_to_measure - set(q for inst in final_measurements for q in inst.locus):
331
340
  # TODO which implementation to use? Now we leave it to None.
332
- c.instructions += (CircuitOperation("measure", tuple(missing), {"key": MEASUREMENT_MODE_KEY}),)
341
+ c.instructions += (
342
+ CircuitOperation(final_measurements_name, tuple(missing), {"key": MEASUREMENT_MODE_KEY}),
343
+ )
333
344
 
334
345
  if heralding_mode != HeraldingMode.NONE:
335
346
  # heralding must return results for the components used in the circuit, if they can be measured
@@ -591,7 +602,12 @@ def derive_readout_mappings(
591
602
  ) -> tuple[list[Circuit_], dict[str, Any]]:
592
603
  """Derive mapping between station acquisition labels and user's measurement keys."""
593
604
  readout_mappings, heralded_components = _build_readout_mappings(
594
- circuits, tuple(circuit_metrics), builder, options.measurement_mode, options.heralding_mode
605
+ circuits,
606
+ tuple(circuit_metrics),
607
+ builder,
608
+ options.measurement_mode,
609
+ options.heralding_mode,
610
+ options.convert_terminal_measurements,
595
611
  )
596
612
  return list(circuits), {"readout_mappings": readout_mappings, "heralded_components": heralded_components}
597
613
 
@@ -747,7 +763,7 @@ def clean_schedule(schedules: Iterable[Schedule], builder: ScheduleBuilder) -> l
747
763
  @compiler_pass
748
764
  def build_playlist(schedules: Iterable[Schedule], builder: ScheduleBuilder) -> tuple[Playlist, dict[str, Any]]:
749
765
  """Build the playlist from the schedules."""
750
- playlist = builder.build_playlist(schedules)
766
+ playlist = builder.build_playlist(schedules)[0]
751
767
  return playlist, {"schedules": schedules} # save the schedules for building settings, debugging, etc
752
768
 
753
769
 
@@ -178,6 +178,8 @@ class CircuitExecutionOptions:
178
178
  move_gate_validation: MoveGateValidationMode
179
179
  move_gate_frame_tracking: MoveGateFrameTrackingMode
180
180
  active_reset_cycles: int | None
181
+ convert_terminal_measurements: bool
182
+ """Iff True, convert terminal measurements to a non-QND, high-fidelity measurement."""
181
183
 
182
184
 
183
185
  ReadoutMapping: TypeAlias = dict[str, tuple[str, ...]]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: iqm-pulla
3
- Version: 9.9.0
3
+ Version: 10.1.0
4
4
  Summary: Client library for pulse-level access to an IQM quantum computer
5
5
  Author-email: IQM Finland Oy <developers@meetiqm.com>
6
6
  License: Apache License
@@ -218,27 +218,27 @@ License-File: LICENSE.txt
218
218
  License-File: AUTHORS.rst
219
219
  Requires-Dist: iqm-exa-common <27,>=26
220
220
  Requires-Dist: iqm-station-control-client <10,>=9
221
- Requires-Dist: iqm-pulse <11,>=10
221
+ Requires-Dist: iqm-pulse <12,>=11
222
222
  Requires-Dist: iqm-data-definitions <3.0,>=2.13
223
223
  Requires-Dist: pylatexenc ==2.10
224
224
  Requires-Dist: pydantic <3.0,>=2.10.4
225
225
  Provides-Extra: notebook
226
226
  Requires-Dist: iqm-exa-common <27,>=26 ; extra == 'notebook'
227
227
  Requires-Dist: iqm-station-control-client <10,>=9 ; extra == 'notebook'
228
- Requires-Dist: iqm-pulse <11,>=10 ; extra == 'notebook'
228
+ Requires-Dist: iqm-pulse <12,>=11 ; extra == 'notebook'
229
229
  Requires-Dist: notebook <7,>=6.4.11 ; extra == 'notebook'
230
230
  Requires-Dist: matplotlib <4,>=3.6.3 ; extra == 'notebook'
231
231
  Requires-Dist: nbclient ~=0.5.10 ; extra == 'notebook'
232
232
  Provides-Extra: qir
233
233
  Requires-Dist: iqm-exa-common <27,>=26 ; extra == 'qir'
234
234
  Requires-Dist: iqm-station-control-client <10,>=9 ; extra == 'qir'
235
- Requires-Dist: iqm-pulse <11,>=10 ; extra == 'qir'
235
+ Requires-Dist: iqm-pulse <12,>=11 ; extra == 'qir'
236
236
  Requires-Dist: iqm-pyqir ==0.12.0 ; extra == 'qir'
237
237
  Requires-Dist: iqm-qiskit-qir ==0.8.0 ; extra == 'qir'
238
238
  Provides-Extra: qiskit
239
239
  Requires-Dist: iqm-exa-common <27,>=26 ; extra == 'qiskit'
240
240
  Requires-Dist: iqm-station-control-client <10,>=9 ; extra == 'qiskit'
241
- Requires-Dist: iqm-pulse <11,>=10 ; extra == 'qiskit'
241
+ Requires-Dist: iqm-pulse <12,>=11 ; extra == 'qiskit'
242
242
  Requires-Dist: iqm-client[qiskit] <31,>=30 ; extra == 'qiskit'
243
243
  Requires-Dist: iqm-client <31,>=30 ; extra == 'qiskit'
244
244
 
@@ -1,13 +1,13 @@
1
1
  iqm/cpc/__init__.py,sha256=qw_SFgwld1YOYYyBE-NSticm60xx5aCAw5LJJzjou8Y,1745
2
2
  iqm/cpc/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
3
3
  iqm/cpc/compiler/__init__.py,sha256=ieYyHzb2IyevDm5swU--rPMsh5GdUtLrw8773Cd0ens,678
4
- iqm/cpc/compiler/compiler.py,sha256=EZvMwkAHgRMGKNsoUQykPPfe6b5WOlyxHuoabvYS35k,20399
4
+ iqm/cpc/compiler/compiler.py,sha256=paWwALMbLQwMBoujKMnUUfybwaoXXYBYHYPLZUXWoyQ,20442
5
5
  iqm/cpc/compiler/dd.py,sha256=j4onTod24RPxRwwsM3EMBBgX4hDO0k_nW9R762AocXo,21674
6
6
  iqm/cpc/compiler/errors.py,sha256=tz-8g1QtDvCAPmAjjCYK3FoULrazkpSTmXIvyqukaT4,1949
7
- iqm/cpc/compiler/standard_stages.py,sha256=YnLfbq0Shfg-zzVzvIqydcnNA022jDg6ehPPz1-Mhts,33954
7
+ iqm/cpc/compiler/standard_stages.py,sha256=j7xSfmV-qgXAnQg21GbvUIbNnBznafQgSc5RrHOWbRA,34560
8
8
  iqm/cpc/compiler/station_settings.py,sha256=l4cJYcNtMar_BoChJaUbmVfpXv7liTCeLWpSv7fAipg,16903
9
9
  iqm/cpc/interface/__init__.py,sha256=mvhNx1I9K5Sg40CwPntWj35M3Bni__23PWEw_qYaXtQ,611
10
- iqm/cpc/interface/compiler.py,sha256=2x3ZhL4WcyjwlSoZ3KhlmRcLxboz_ptS0M_rdX1z0c8,9861
10
+ iqm/cpc/interface/compiler.py,sha256=_3sFYVoqqGH7XyBpYm2bLPnnz-1wiBuUee6WYdFJeXE,9992
11
11
  iqm/pulla/__init__.py,sha256=fj5Qh8R9K-z6q5g9-CySBZsG8d33nU7hCHrqIIB8_-0,901
12
12
  iqm/pulla/calibration.py,sha256=c_SNlTxXC0y-ahDY7JY53N7SofU5WUWMrNBogtdfHl4,4523
13
13
  iqm/pulla/interface.py,sha256=yymQo4REHYcUOWgPxPYq9IixS9bBZ27LXLQgJhzET58,5400
@@ -19,9 +19,9 @@ iqm/pulla/utils_cirq.py,sha256=VtdO356D2RAh2lSVdaPm3ClJ9-nvC4jzhR9hP5QSQhI,793
19
19
  iqm/pulla/utils_dd.py,sha256=SxYAuRBgvYELKjeXpFbP4mM0xCCivDk7WUHw7oEXfMo,1695
20
20
  iqm/pulla/utils_qir.py,sha256=SJK8N8xZyv9seXj1lJJfyt3YMht50VzUxzm8NiblSEw,11575
21
21
  iqm/pulla/utils_qiskit.py,sha256=4NTNDWICFh3B0v509w3CfBHrB-GzBm-2TMlKRfgkTTI,10485
22
- iqm_pulla-9.9.0.dist-info/AUTHORS.rst,sha256=iCStz7WP5Jk7uMnn9jRA4ybS14X4yeUW2SsWE-OTaRk,328
23
- iqm_pulla-9.9.0.dist-info/LICENSE.txt,sha256=cCj_biRA4Q8A77vxR8AuvAf-DZ5G79yxR_3lYY6TrmA,11333
24
- iqm_pulla-9.9.0.dist-info/METADATA,sha256=XoPOJJpIKqvquNfQnuNwB2h-7d8Zbe7TQ0WwXd7Whp0,17695
25
- iqm_pulla-9.9.0.dist-info/WHEEL,sha256=y4mX-SOX4fYIkonsAGA5N0Oy-8_gI4FXw5HNI1xqvWg,91
26
- iqm_pulla-9.9.0.dist-info/top_level.txt,sha256=NB4XRfyDS6_wG9gMsyX-9LTU7kWnTQxNvkbzIxGv3-c,4
27
- iqm_pulla-9.9.0.dist-info/RECORD,,
22
+ iqm_pulla-10.1.0.dist-info/AUTHORS.rst,sha256=iCStz7WP5Jk7uMnn9jRA4ybS14X4yeUW2SsWE-OTaRk,328
23
+ iqm_pulla-10.1.0.dist-info/LICENSE.txt,sha256=cCj_biRA4Q8A77vxR8AuvAf-DZ5G79yxR_3lYY6TrmA,11333
24
+ iqm_pulla-10.1.0.dist-info/METADATA,sha256=cDHFIPpHWXyeYjePNu1h6jYRmCmElMg77wLtc-dxEqs,17696
25
+ iqm_pulla-10.1.0.dist-info/WHEEL,sha256=y4mX-SOX4fYIkonsAGA5N0Oy-8_gI4FXw5HNI1xqvWg,91
26
+ iqm_pulla-10.1.0.dist-info/top_level.txt,sha256=NB4XRfyDS6_wG9gMsyX-9LTU7kWnTQxNvkbzIxGv3-c,4
27
+ iqm_pulla-10.1.0.dist-info/RECORD,,