qml.devices.MCMConfig¶
-
class
MCMConfig
(mcm_method=None, postselect_mode=None)[source]¶ Bases:
object
A class to store mid-circuit measurement configurations.
Attributes
Which mid-circuit measurement strategy to use.
Configuration for handling shots with mid-circuit measurement postselection.
-
mcm_method
: Optional[str] = None¶ Which mid-circuit measurement strategy to use. Use
deferred
for the deferred measurements principle and “one-shot” if using finite shots to execute the circuit for each shot separately. If not specified, the device will decide which method to use.
-
postselect_mode
: Optional[str] = None¶ Configuration for handling shots with mid-circuit measurement postselection. If
"hw-like"
, invalid shots will be discarded and only results for valid shots will be returned. If"fill-shots"
, results corresponding to the original number of shots will be returned. If not specified, the device will decide which mode to use.
-