Skip to content

Commit

Permalink
Merge pull request #256 from nonhermitian/undo-batch-setting
Browse files Browse the repository at this point in the history
Do not use runtime mode implicitly
  • Loading branch information
nonhermitian authored Oct 23, 2024
2 parents 935c17b + e56193e commit 54b2d76
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docs/runtime.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ in `mthree.M3Mitigation.cals_from_system`. For example:
mit.cals_from_system(runtime_mode=batch); # This is where the Batch or Session goes


Note that if no `runtime_mode` is set, and the passed system is an IBM backend, then jobs are submitted in `Batch` mode automatically. This mode is NOT closed by default, allowing users to include additional jobs. This mode can be accessed via `mode = mit.system.get_mode()`
Note that if no `runtime_mode` is set, and the passed system is an IBM backend, then jobs are submitted in `Job` mode, i.e. independently, by default.
4 changes: 1 addition & 3 deletions mthree/mitigation.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,9 +165,7 @@ def cals_from_system(

if isinstance(self.system, rm.RunningManBackend):
if runtime_mode:
self.system.set_mode(runtime_mode, overwrite=True)
elif not self.system.get_mode():
self.system.set_mode("batch")
self.system.set_mode(runtime_mode)
if qubits is None:
qubits = range(self.num_qubits)
# Remove faulty qubits if any
Expand Down

0 comments on commit 54b2d76

Please sign in to comment.