3.7.12. qupulse.pulses.point_pulse_template¶
Classes
|
Create new instance of TableEntry(t, v, interp) |
|
Initializes a Serializable. |
Exceptions
|
- exception qupulse.pulses.point_pulse_template.InvalidPointDimension(expected, received)[source]¶
Bases:
Exception
- class qupulse.pulses.point_pulse_template.PointPulseEntry(t: Union[qupulse.expressions.sympy.ExpressionScalar, str, numbers.Real], v: Union[qupulse.expressions.sympy.ExpressionScalar, str, numbers.Real], interp: Optional[Union[str, qupulse.pulses.interpolation.InterpolationStrategy]] = 'default')[source]¶
Bases:
qupulse.pulses.table_pulse_template.TableEntry
Create new instance of TableEntry(t, v, interp)
- instantiate(parameters: Dict[str, numbers.Real], num_channels: int) Sequence[qupulse.program.waveforms.TableWaveformEntry] [source]¶
- class qupulse.pulses.point_pulse_template.PointPulseTemplate(time_point_tuple_list: List[Union[TableEntry, Tuple[Union[qupulse.expressions.sympy.ExpressionScalar, str, numbers.Real], Union[qupulse.expressions.sympy.ExpressionScalar, str, numbers.Real]], Tuple[Union[qupulse.expressions.sympy.ExpressionScalar, str, numbers.Real], Union[qupulse.expressions.sympy.ExpressionScalar, str, numbers.Real], Union[str, qupulse.pulses.interpolation.InterpolationStrategy]]]], channel_names: Sequence[Union[str, int]], *, parameter_constraints: Optional[List[Union[str, qupulse.pulses.parameters.ParameterConstraint]]] = None, measurements: Optional[List[Tuple[str, Union[qupulse.expressions.sympy.Expression, str, numbers.Real], Union[qupulse.expressions.sympy.Expression, str, numbers.Real]]]] = None, identifier: Optional[str] = None, registry: Optional[MutableMapping[str, Serializable]] = None)[source]¶
Bases:
qupulse.pulses.pulse_template.AtomicPulseTemplate
,qupulse.pulses.parameters.ParameterConstrainer
Initializes a Serializable.
- Parameters
identifier – 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: Dict[str, numbers.Real], channel_mapping: Dict[Union[str, int], Optional[Union[str, int]]]) Optional[Union[qupulse.program.waveforms.TableWaveform, qupulse.program.waveforms.MultiChannelWaveform]] [source]¶
Implements
build_waveform()
.
- property defined_channels: Set[Union[str, int]]¶
Implements
defined_channels
.
- property duration: qupulse.expressions.sympy.Expression¶
Implements
duration
.
- property final_values: Dict[Union[str, int], qupulse.expressions.sympy.ExpressionScalar]¶
Values of defined channels at t == self.duration
- get_serialization_data(serializer: Optional[qupulse.serialization.Serializer] = None) Dict[str, Any] [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.
- 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 initial_values: Dict[Union[str, int], qupulse.expressions.sympy.ExpressionScalar]¶
Values of defined channels at t == 0
- property integral: Dict[Union[str, int], qupulse.expressions.sympy.ExpressionScalar]¶
Implements
integral
.
- property parameter_names: Set[str]¶
Implements
parameter_names
.
- property point_pulse_entries: Sequence[qupulse.pulses.point_pulse_template.PointPulseEntry]¶
- qupulse.pulses.point_pulse_template.PointWaveform¶
- qupulse.pulses.point_pulse_template.PointWaveformEntry¶