Schedule.draw(dt=1, style=None, filename=None, interp_method=None, scale=None, channel_scales=None, plot_all=False, plot_range=None, interactive=False, table=False, label=False, framechange=True, channels=None, show_framechange_channels=True)[소스]

Plot the schedule.

  • dt (float) – Time interval of samples.

  • style (Optional[SchedStyle]) – A style sheet to configure plot appearance.

  • filename (Optional[str]) – Name required to save pulse image.

  • interp_method (Optional[Callable]) – A function for interpolation.

  • scale (Optional[float]) – Relative visual scaling of waveform amplitudes, see Additional Information.

  • channel_scales (Optional[Dict[Channel, float]]) – Channel independent scaling as a dictionary of Channel object.

  • plot_all (bool) – Plot empty channels.

  • plot_range (Optional[Tuple[float]]) – A tuple of time range to plot.

  • interactive (bool) – When set true show the circuit in a new window (this depends on the matplotlib backend being used supporting this).

  • table (bool) – Draw event table for supported commands.

  • label (bool) – Label individual instructions.

  • framechange (bool) – Add framechange indicators.

  • channels (Optional[List[Channel]]) – A list of Channels to plot.

  • show_framechange_channels (bool) – Plot channels with only framechanges.

Additional Information:

If you want to manually rescale the waveform amplitude of channels one by one, you can set channel_scales argument instead of scale. The channel_scales should be given as a python dictionary:

channel_scales = {pulse.DriveChannels(0): 10.0,
                  pulse.MeasureChannels(0): 5.0}

When the channel to plot is not included in the channel_scales dictionary, scaling factor of that channel is overwritten by the value of scale argument. In default, waveform amplitude is normalized by the maximum amplitude of the channel. The scaling factor is displayed under the channel name alias.


A matplotlib figure object of the pulse schedule.

반환 형식