3.6.11. qupulse.pulses.point_pulse_template

qupulse.pulses.point_pulse_template.PointWaveform

alias of qupulse._program.waveforms.TableWaveform

class qupulse.pulses.point_pulse_template.PointPulseTemplate(time_point_tuple_list, channel_names, *, parameter_constraints=None, measurements=None, identifier=None, registry=None)[source]

Bases: qupulse.pulses.pulse_template.AtomicPulseTemplate, qupulse.pulses.parameters.ParameterConstrainer

Initializes a Serializable.

Parameters

identifier (Optional[str]) – An optional, non-empty identifier for this Serializable. If set, this Serializable will always be stored as a separate data item and never be embedded.

Raises

ValueError – If identifier is the empty string

build_waveform(parameters, channel_mapping)[source]

Implements build_waveform().

Return type

Optional[TableWaveform]

property defined_channels

Implements defined_channels.

Return type

Set[Union[str, int]]

property duration

Implements duration.

Return type

Expression

get_serialization_data(serializer=None)[source]

Returns all data relevant for serialization as a dictionary containing only base types.

Implementation hint: In the old serialization routines, if the Serializable contains complex objects which are itself Serializables, a serialized representation for these MUST be obtained by calling the dictify() method of serializer. The reason is that serializer may decide to either return a dictionary to embed or only a reference to the Serializable subelement. This is DEPRECATED behavior as of May 2018. In the new routines, this will happen automatically and every Serializable is only responsible for returning it’s own data and leave nested Serializables in object form.

For the transition time where both implementations are available, implementations of this method should support the old and new routines, using the presence of the serializer argument to differentiate between both. Don’t make use of the implementation in this base class when implementing this method for the old routines.

Parameters

serializer (Serializer) – DEPRECATED (May 2018).A Serializer instance used to serialize complex subelements of this Serializable.

Return type

Dict[str, Any]

Returns

A dictionary of Python base types (strings, integers, lists/tuples containing these,

etc..) which fully represent the relevant properties of this Serializable for storing and later reconstruction as a Python object.

property integral

Implements integral.

Return type

Dict[Union[str, int], ExpressionScalar]

property parameter_names

Implements parameter_names.

Return type

Set[str]

property point_parameters
Return type

Set[str]

property point_pulse_entries
Return type

Sequence[PointPulseEntry]

class qupulse.pulses.point_pulse_template.PointPulseEntry[source]

Bases: qupulse.pulses.table_pulse_template.TableEntry

Create new instance of TableEntry(t, v, interp)

instantiate(parameters, num_channels)[source]
Return type

Sequence[TableWaveformEntry]

qupulse.pulses.point_pulse_template.PointWaveformEntry

alias of qupulse._program.waveforms.TableWaveformEntry

exception qupulse.pulses.point_pulse_template.InvalidPointDimension(expected, received)[source]

Bases: Exception