Pulse

The Boulder Opal Toolkits are currently in beta phase of development. Breaking changes may be introduced.

class Pulse(function, duration)

A class that contains information about a pulse that can be discretized.

You can use this class to create and store pulses that will be sent to third-party devices. The pulses created in this way are independent of Boulder Opal graphs and have a fixed time step between their segments.

Parameters
  • function (Callable) – A function that returns the value of the pulse at each instant of time. It must be capable of accepting a NumPy array of times as an input parameters, in which case it should return the values of the function for all the times passed.

  • duration (float) – The duration of the pulse.

Methods

export_with_sampling_rate

Return the values of the pulse sampled at a constant rate given by the sampling rate provided.

export_with_time_step

Return the values of the pulse sampled at a constant rate given by the time step provided.