PlayedWaveforms

Contents

PlayedWaveforms#

class pulserver.validate.PlayedWaveforms[source]#

Bases: object

What a scanner played, as its plotter recorded it.

One pair of arrays per channel: the time of each sample in µs, and its amplitude in the unit that channel is stored in. Gradients are in gauss per centimetre (gradient_mt_per_m() converts them) and transmit channels in converter counts (phase_rad() converts the phase). The magnitude’s scale is the peak transmit field of the scan played, which the file does not hold, so a magnitude is compared by its shape.

Attributes:
  • end_time_us (float) – The length of the recording, as the file states it.

  • channels (dict[str, tuple[numpy._typing._array_like.NDArray[numpy.int64], numpy._typing._array_like.NDArray[numpy.float64]]]) – (time_us, amplitude) per channel: gx, gy and gz, ssp, and the transmit rho, theta and omega.

  • titles (dict[str, str]) – What the file calls each sequencer, which names its core and hardware.

Methods

get

Return a channel, or a pair of empty arrays where it played nothing.

gradient_mt_per_m

Return a gradient channel in millitesla per metre.

phase_rad

Return the transmit phase in radians, wrapped to one turn.

Attributes