Shortcuts

qiskit.transpiler.FlowController

class FlowController(passes, options, **partial_controller)[ソース]

Base class for multiple types of working list.

This class is a base class for multiple types of working list. When you iterate on it, it returns the next pass to run.

__init__(passes, options, **partial_controller)[ソース]

Initialize self. See help(type(self)) for accurate signature.

Methods

__init__(passes, options, **partial_controller)

Initialize self.

add_flow_controller(name, controller)

Adds a flow controller.

controller_factory(passes, options, …)

Constructs a flow controller based on the partially evaluated controller arguments.

dump_passes()

Fetches the passes added to this flow controller.

remove_flow_controller(name)

Removes a flow controller.

Attributes

registered_controllers

classmethod add_flow_controller(name, controller)[ソース]

Adds a flow controller.

パラメータ
  • name (string) – Name of the controller to add.

  • controller (type(FlowController)) – The class implementing a flow controller.

classmethod controller_factory(passes, options, **partial_controller)[ソース]

Constructs a flow controller based on the partially evaluated controller arguments.

パラメータ
  • passes (list[BasePass]) – passes to add to the flow controller.

  • options (dict) – PassManager options.

  • **partial_controller (dict) – Partially evaluated controller arguments in the form {name:partial}

例外

TranspilerError – When partial_controller is not well-formed.

戻り値

A FlowController instance.

戻り値の型

FlowController

dump_passes()[ソース]

Fetches the passes added to this flow controller.

戻り値

{『options』: self.options, 『passes』: [passes], 『type』: type(self)}

戻り値の型

dict

classmethod remove_flow_controller(name)[ソース]

Removes a flow controller.

パラメータ

name (string) – Name of the controller to remove.

例外

KeyError – If the controller to remove was not registered.

表示 lang: Japanese
言語
English
Japanese
German
Korean