The MRiLab is a numerical MRI simulation package. It has been developed and optimized to simulate MR signal formation, k-space acquisition and MR image reconstruction. MRiLab provides several dedicated toolboxes to analyze RF pulse, design MR sequence, configure multiple transmitting and receiving coils, investigate magnetic field related properties and evaluate real-time imaging technique. The main MRiLab simulation platform combined with those toolboxes can be applied to customize various virtual MR experiments which can serve as a prior stage for prototyping and testing new MR technique and application.
The MRiLab features highly interactive graphical user interface (GUI) for the convenience of fast experiment design and technique prototyping. High simulation accuracy is achieved by simulating discrete spin evolution at small time interval using the Bloch-equation and appropriate tissue model. In order to manipulate large multidimensional spin array, MRiLab employs parallel computing by incorporating latest graphical processing unit (GPU) technique and multi-threading CPU technique. With efficient parallelization, MRiLab can accomplish multidimensional multiple spin species MR simulation at high simulation accuracy and time efficiency, and with low computing hardware cost.
The current MRiLab version (v1.3) is made available online. MRiLab is
released as a free software. This means that you are free to use and modify this
software as your needs, as long as you acknowledge the original author in any
future work. If you find MRiLab useful for the publication of any scientific
results, including a line in your acknowledgments section for MRiLab is
requested.
MRiLab downloading address:
We also request you to cite this scientific paper:
Fang Liu, Julia V. Velikina, Walter F. Block, Richard Kijowski and Alexey A. Samsonov: Fast Realistic MRI Simulations Based on Generalized Multi-Pool Exchange Tissue Model, IEEE Trans. Med. Imag., doi: 10.1109/TMI.2016.2620961, 2016.
To use MRiLab, you need to install Matlab software first. The current MRiLab version was successfully tested under mutiple Matlab versions:
To install MRiLab, you need to download MRiLab source code, then extract the
MRiLab root folder, put the folder to any location in you computer. To run MRiLab,
start Matlab, then simply run the ‘MRiLab.m’ script under the MRiLab root folder.
The GUIs in MRiLab is developed under Matlab GUI development environment
(GUIDE). Majority of the simulation configuration code is programmed
using pure Matlab language and Extensible Markup Language (XML). The
computing intensive functions are programmed and optimized using MATLAB
Executable (MEX) C code. These MEX binaries include GPU computing
kernels that interact with GPU devices via NVIDIA Compute Unified Device
Architecture (CUDA), and CPU kernels with multi-threading via Open
Multi-Processing (OpenMP) for multi-core CPU. Other MEX binaries include
several 3D image rendering functions using Visualization Toolkit (VTK).
These MEX library binaries have been built under 64-bit Windows and Linux
OS system and shipped with MRiLab source code. However, if they are
incompatible with your OS system for any reason or if you wish to modify these
MEX files for your own good, you need to recompile them from source code.
Before recompiling these MEX files, some dependent packages are required.
Intel IPP : http://software.intel.com/en-us/intel-ipp
AMD Framewave : http://framewave.sourceforge.net
NVIDIA : http://www.nvidia.com/page/home.html
CUDA : http://www.nvidia.com/object/cuda_home_new.html
Although GPU acceleration dramatically improves computational efficiency, the GPU computing mode is also optional. Alternatively, MRiLab provides multi-threading CPU computing mode via OpenMP which requires no additional packages on modern operating system. The CPU kernel provides the same simulation accuary but with reduced computational efficiency compared to GPU mode.
VTK : http://www.vtk.org
ISMRMRD : http://ismrmrd.sourceforge.net/#obtaining-and-installing
After completing abovementioned dependent packages, you also need to add a few environment variables in your system :
Note that the C source code for these MEX files is in /MRiLab/Lib/src folder. To compile and install MEX files
You also can use cmake-gui for configuration and other building tools (e.g. Eclipse) for building the binaries.
If installation problems do occur in your case, feel free to leave comments on the online supporting forum. For your information, I provide here my development environment (Table 1.1) for the current MRiLab version.
Environment | Desktop | Desktop |
Machine | Dell Precision T3500 | Dell Precision T3500 |
CPU | Intel Xeon W3530 | Intel Xeon W3530 |
GPU | NVIDIA Quadro K4000 | NVIDIA Quadro K4000 |
OS | Windows 7 64-bit | Linux Ubuntu 14.04LTS 64-bit |
Matlab | Matlab R2015a 64-bit | Matlab R2015a 64-bit |
C Compiler | Visual Studio 10 Win64 | GCC 4.8.4 |
VTK | VTK 5.10 | VTK 6.3 |
CUDA | CUDA 7.0.28 | CUDA 7.0.28 |
IPP | Intel IPP 7.0 | Intel IPP 7.0 |
Framewave | AMD Framewave 1.3 | AMD Framewave 1.3 |
ISMRMRD | ISMRMRD 0.5.0 | ISMRMRD 0.5.0 |
Boost | Boost 1.53.0 | Boost 1.54.0 |