sample_from_piecewise_linear¶
- qugradlab.pulses.sampling.sample_from_piecewise_linear(signal: ndarray[complex], fractional_indices: ndarray[float]) Any[source]¶
Samples from a piecewise linear signal.
- Parameters:
signal (NDArray[Shape[n_points, Any_Shape], complex]) – The piecewise linear signal to sample from
fractional_indices (NDArray[Shape[n_sample_points], complex]) – Each entry will correspond to a sample. The integral part of each entry corresponds to the index
iin the signal and the fractional part corresponds to the convex combination of the points at indicesiandi+1.
- Returns:
The sampled signal.
- Return type:
NDArray[Shape[n_sample_points,
signal.shape[1:]], complex]