MPRAGESimulator#
- class blochsim.simulators.MPRAGESimulator[source]#
Bases:
SimulatorMPRAGE: an inversion followed by a spoiled gradient-echo train.
One inversion, then a train of spoiled gradient-echo readouts of which one, the k-space centre, is sampled.
TIis measured from the inversion to that shot. The signal is one complex sample per voxel.- Parameters:
TI (float or array-like) – Inversion time, in ms, from the inversion to the sampled shot.
flip (float or array-like) – Excitation flip angle, in degrees; scalar, or one per shot.
TRspgr (float or array-like) – Repetition time of one readout, in ms.
nshots (int or array-like) – Readouts in the block. A scalar is the total, sampled shot included, split evenly around it;
(before, after)gives the readouts before and after the sampled shot, so the block holdsbefore + after + 1.phases (float or array-like, default=0.0) – Excitation phases, in degrees; scalar or one per shot.
states (int, default=1) – Configuration states; only the longitudinal state is carried.
record ({"all", "acquired"}, default="acquired") – Samples recorded: only the sampled shot.
- Tissue properties:
T1 (float or array-like) – Longitudinal relaxation time, in ms.
M0 (float or array-like, default=1.0) – Equilibrium magnetization.
inv_efficiency (float or array-like, default=1.0) – Fraction of a perfect inversion.
Examples
from blochsim.simulators import MPRAGESimulator sequence = MPRAGESimulator(TI=500.0, flip=5.0, TRspgr=5.0, nshots=128) signal = sequence.simulate(T1=(200.0, 1000.0), inv_efficiency=0.95)
Methods
bindReturn a copy with further arguments fixed.
describeReturn the
SequenceDescriptionof a protocol.Return the acquired sample.
from_descriptionReturn a simulator that plays an existing description.
from_pulseqReturn a simulator over one repetition of a Pulseq sequence.
jacobianReturn the signal and its derivative with respect to tissue properties.
Return the inversion and the train, with one shot marked as acquired.
playedReturn the protocol arguments of
layout(), arrays as torch tensors.repetition_sReturn the duration of one repetition in seconds.
simulateReturn the recorded signal.
- layout()[source]#
Return the inversion and the train, with one shot marked as acquired.
- Raises:
ValueError – If the inversion time falls before the first excitation, or
flipis neither scalar nor one per shot.