Call¶
- class Call(subroutine, value_dict=None, name=None)[fuente]¶
Bases:
Instruction
Pulse
Call
instruction.The
Call
instruction represents the calling of a referenced subroutine (schedule). It enables code reuse both within the pulse representation and hardware (if supported).Define new subroutine.
Nota
Inline subroutine is mutable. This requires special care for modification.
- Parámetros
subroutine (Union[Schedule, ScheduleBlock]) – A program subroutine to be referred to.
value_dict (
Optional
[Dict
[ParameterExpression
,Union
[ParameterExpression
,float
]]]) – Mapping of parameter object to assigned value.name (
Optional
[str
]) – Unique ID of this subroutine. If not provided, this is generated based on the subroutine name.
- Muestra
PulseError – If subroutine is not valid data format.
Methods
Return a new
Schedule
withschedule
inserted at the maximum time over all channels shared betweenself
andschedule
.Returns this subroutine with the parameters assigned.
Return duration of the supplied channels in this Instruction.
Return minimum start time for supplied channels.
Return maximum start time for supplied channels.
Plot the instruction.
Return a new
Schedule
withschedule
inserted withinself
atstart_time
.Return True iff the instruction is parameterized.
Return a new schedule shifted forward by time.
Attributes
- arguments¶
Parameters dictionary to be assigned to subroutine.
- Tipo del valor devuelto
Dict
[ParameterExpression
,Union
[ParameterExpression
,float
]]
- duration¶
Duration of this instruction.
- Tipo del valor devuelto
Union
[int
,ParameterExpression
]
- id¶
Unique identifier for this instruction.
- Tipo del valor devuelto
int
- instructions¶
Iterable for getting instructions from Schedule tree.
- Tipo del valor devuelto
Tuple
[Tuple
[int
,Instruction
]]
- name¶
Name of this instruction.
- Tipo del valor devuelto
str
- operands¶
Return instruction operands.
- Tipo del valor devuelto
Tuple
- parameters¶
Unassigned parameters which determine the instruction behavior.
- Tipo del valor devuelto
Set
- prefix = 'call'¶
- start_time¶
Relative begin time of this instruction.
- Tipo del valor devuelto
int
- stop_time¶
Relative end time of this instruction.
- Tipo del valor devuelto
int
- subroutine¶
Return attached subroutine.
- Devuelve
The program referenced by the call.
- Tipo del valor devuelto
program (Union[Schedule, ScheduleBlock])