Skip to content

Latest commit

 

History

History
80 lines (52 loc) · 2.9 KB

README_HOME.md

File metadata and controls

80 lines (52 loc) · 2.9 KB

MRTwin_pulseq for your home system

Get the MRTwin_pulseq package

Downloading Python, Pytorch and Spyder

Python is free to download and is available on all types of operating systems. We recommend to install Anaconda. For Linux see https://docs.anaconda.com/anaconda/install/linux/. For windows see https://www.anaconda.com/distribution/windows . In addition to python some extension packages are required like Pytorch. Install them by using the following commands in the "Anaconda Prompt".

 e.g. without gpu:
 conda install pytorch torchvision cpuonly -c pytorch
 
 with gpu:
 conda install pytorch torchvision cudatoolkit=11.6 -c pytorch -c conda-forge
  • The MRTwin_pulseq simulation itself requires the MRzero Core for simulation. Install it with:
 On Windows and Linux (requires python > 3.7):
 pip install MRzeroCore

 On Mac:
 not yet supported

If not already installed you also need pypulseq, torchkbnufft, numpy, scipy and matplotlib.

All required packages can be installed by

pip install mrzerocore
pip install pypulseq==1.3.1.post1
pip install torchkbnufft==1.3.0 --no-deps
pip install scikit-image
pip install PyWavelets

Versions that were tested

  • pypulseq.version : '1.3.1post1'
  • torch.version : '1.3.0' and '1.7.0'
  • np.version : '1.18.1' and '1.19.2'
  • scipy.version: '1.4.1' and '1.5.2'
  • matplotlib.version: '3.1.1'
  • torchkbnufft.version: '1.3.0'

You can also run file ./ex/ex_help01_python.py to test versions.

Starting Spyder at your own PC

Run Spyder from the anaconda environment.

Check the installation

See if you can run the python files ex/ex_help_01_python and ex/exB05. If errors occur check the versions of the required packages. Or get help from the admin.

General Settings of Spyder

To have plots as separate window, which allows resizing and zooming, go to Tools->Preferences. Then on the rider IPythonKonsole go to Graphics and choose for the graphics backend: Automatic.

Then you have to close and restart spyder.

I recommend to switch the layout to matlab layout. Go to View->Layouts -> Matlab Layout or Rstudio Layout.

Once this is set up, make the project code folder MRTwin_pulseq/ex your current folder.

Diff tool

If you want compare changed files or sample solutions you can use the tools diff, or more visually advanced Kompare or Meld.