Skip to content

Commit

Permalink
Update render sample_rate.
Browse files Browse the repository at this point in the history
  • Loading branch information
Luc Blom committed Mar 15, 2018
1 parent 8fbaa1f commit ead9988
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion qctoolkit/pulses/plotting.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,14 @@ def iter_waveforms(instruction_block: AbstractInstructionBlock,
raise NotImplementedError('Rendering cannot handle instructions of type {}.'.format(type(instruction)))


def render(sequence: AbstractInstructionBlock, sample_rate: int=10) -> Tuple[np.ndarray, Dict[ChannelID, np.ndarray]]:
def render(sequence: AbstractInstructionBlock, sample_rate: float=10) -> Tuple[np.ndarray, Dict[ChannelID, np.ndarray]]:
"""'Render' an instruction sequence (sample all contained waveforms into an array).
Args:
sequence (AbstractInstructionBlock): block of instructions representing a (sub)sequence
in the control flow of a pulse template instantiation.
sample_rate (float): The sample rate in GHz.
Returns:
a tuple (times, values) of numpy.ndarrays of similar size. times contains the time value
of all sample times and values the corresponding sampled value.
Expand Down

0 comments on commit ead9988

Please sign in to comment.