nlop.Bloch

Contents

nlop.Bloch#

bartorch.nlop.Bloch()#

Any TorchSim sequence as a model operator, through Bloch simulation.

Fits a Bloch simulation of the sequence rather than a closed-form signal equation, so it serves sequences that have none: an FSE train, a fingerprinting schedule, a bSSFP sweep, or a sequence of your own – anything with a simulate becomes an operator Gauss-Newton can solve.

Parameters:
  • acquisition (torchsim Simulator) – The sequence, with everything not being solved for already fixed on it. A property bound as a map – a measured B1, a known T1 – is one value per voxel and rides along.

  • *unknown (str) – The properties being solved for, in the order their channels appear.

  • shape (tuple of int, default=()) – The voxel shape, C order.

  • bounds (dict, default=None) – {name: (low, high)}, either end None for unbounded. A bound is kept by solving for a transformed variable, so no iterate leaves it.

  • amplitude (bool, default=True) – Carry a complex amplitude multiplying the simulated signal.

  • subspace (torchsim.Subspace, default=None) – Solve in a temporal basis rather than in the contrasts.

  • contrasts (int, default=None) – How many images the sequence records; measured when not given.

  • **scale – The size of a step in a parameter left unbounded.

Examples

>>> from torchsim.simulators import FSESimulator
>>> M = Bloch(
...     FSESimulator(flip=train, ESP=8.0, TR=3000.0),
...     "T1", "T2",
...     shape=(128, 128),
...     bounds={"T1": (100.0, 4000.0), "T2": (5.0, 500.0)},
... )