Differences between revisions 1 and 43 (spanning 42 versions)
Revision 1 as of 15:06:40 13-08-2012
Size: 5847
Comment: Local Merge - 'FslDev'
Revision 43 as of 12:52:36 16-02-2024
Size: 4190
Editor: PaulMcCarthy
Comment:
Deletions are marked like this. Additions are marked like this.
Line 4: Line 4:
FSL is available ready to run for Mac OS X and Linux (Centos or Debian/Ubuntu) - with Windows computers being supported with a Linux Virtual Machine. We also provide source code if you run an OS not directly supported by us. FSL is available ready to run for macOS (Intel and M1/M2) and Linux, with Windows computers being supported via the Windows Subsystem for Linux (WSL). Source code is downloaded and installed part of a standard installation, if you wish to compile the code yourself.
Line 7: Line 7:
The FSL software can be downloaded from the link below: We strongly recommend that the FSL software is downloaded and installed using the ''fslinstaller.py'' script available from the link below:
Line 9: Line 9:
 * [[http://www.fmrib.ox.ac.uk/fsldownloads|Download FSL]]  * [[http://fsl.fmrib.ox.ac.uk/fsldownloads|Download FSL]]
Line 11: Line 11:
Once you have downloaded the installation package you can install it on your computer by following these instructions: Once you have downloaded the installer, ''fslinstaller.py'', you can use it to install FSL on your computer by following these instructions (click on the appropriate link now, as the next steps for installing are described in the linked pages, not in the sections immediately below here):
Line 13: Line 13:
 * [[FslInstallation/MacOsX|Mac OS X]]  * [[FslInstallation/MacOsX|macOS]]
Line 16: Line 16:
 * [[FslInstallation/SourceCode|Source Compilation]]
Line 18: Line 17:
To download older ( prior to FSL 6.0.6 ) versions of the FSL, the previous version of the installer can be downloaded [[https://git.fmrib.ox.ac.uk/fsl/installer/-/raw/master/fslinstaller.py?inline=false|here]].

----


----
Line 20: Line 25:
If you have used the [[FslInstallation/FslInstaller|FSL Install script]] your shell will have been configured to run the FSL tools. See our [[FslInstallation/ShellSetup|shell setup guide]] for details on what this script does and how you can set this up system-wide. The [[FslInstallation/FslInstaller|FSL Install script]] will setup your computer such that you can run the FSL tools from a terminal. See our [[FslInstallation/ShellSetup|shell setup guide]] for details on what this script does. On Linux computers it can also be used to configure FSL for all users on the computer.
Line 23: Line 28:
Once your shell is configured, you can run the FSL tools from the command line; the tools are stored in `$FSLDIR/bin` and this location will have been added to your terminal's search locations for ease of use. Once your account is configured for FSL use, you can run the FSL tools from the command line; the tools are stored in `$FSLDIR/share/fsl/bin` and this location will have been added to your terminal's search locations for ease of use.
Line 25: Line 30:
In general, command-line programs are lower case (e.g. `bet`), with the GUI version capitalised (e.g. `Bet`), except on Mac OS X, where you need to append `_gui` because it can't tell the difference between upper and lower case filenames (e.g. `Bet_gui`). In general, command-line programs are lower case (e.g. `bet`), with the GUI version capitalised (e.g. `Bet`), except on macOS, where you need to append `_gui` because it can't tell the difference between upper and lower case filenames (e.g. `Bet_gui`).
Line 29: Line 34:
= Customising =
There are several options you can set to change the way FSL behaves. These options are set using [[http://en.wikipedia.org/wiki/Environment_variable|environment variables]], see our page on [[FslEnvironmentVariables|FSL environment variables]] for details on what can be configured, or look in the files `${FSLDIR}/etc/fslconf/fsl.sh` (if you use BASH/DASH) or `${FSLDIR}/etc/fslconf/fsl.csh` (if you use CSH/TCSH)([[WhatShellAmIRunning|what shell am I using?]]).

When the shell [[FslInstallation/ShellSetup|setup commands]] are sourced, default settings are applied. You can override these defaults by creating a folder `.fslconf` in your home folder and creating a file `fsl.sh` (BASH users) or `fsl.csh` (TCSH users) within it. This file should contain new definitions for any settings you wish to change.

For example, to change the output file format of the FSL tools to NIFTI pairs, do the following:

 1. Create the configuration folder
 {{{#!highlight bash numbers=disable
mkdir ~/.fslconf
cd ~/.fslconf
}}}
 1. Create the `fsl.sh` (or `fsl.csh`) file with the `FSL_OUTPUTTYPE` environment variable set to `NIFTI_PAIR` For BASH users:
 {{{#!highlight bash numbers=disable
echo "FSL_OUTPUTTYPE=NIFTI_PAIR" > fsl.sh
echo "export FSL_OUTPUTTYPE" >> fsl.sh
}}}
 For TCSH users:
 {{{#!highlight tcsh numbers=disable
echo "setenv FSL_OUTPUTTYPE NIFTI_PAIR" > fsl.csh
}}}

Alternatively, if the `fsl.sh` file already exists you can edit it with the text editor of your choice.

{{{#!wiki warning
'''DO NOT copy the centrally installed files into ~/.fslconf'''

If you copy the `${FSLDIR}/etc/fslconf/fsl.sh` or `${FSLDIR}/etc/fslconf/fsl.sh` into `~/.fslconf` you will cause a loop that will stop you from being able to log in!
}}}
We recommend that you only change the FSL settings that differ from the defaults in your `~/.fslconf/fsl.sh` (or `fsl.csh`) and nothing else.

If you wish to change the settings for all users you can create the file `/etc/fslconf/fsl.sh` (or `/etc/fslconf/fsl.csh`) on a machine by machine basis. Where you wish to store the settings centrally, we also check the file `/usr/local/etc/fslconf/fsl.sh` (or `fsl.csh` equivalent) so you could perhaps NFS mount this folder.
----
Line 65: Line 39:
----
Line 73: Line 48:
All the above tools interact with a compute cluster via a single central script `fsl_sub`; if no cluster is available then this script silently runs all the requested jobs in series. To customise FSL for your local compute cluster and clustering software, simply edit `${FSLDIR}/bin/fsl_sub` - hopefully the comments in this file are sufficient to make this fairly painless, particularly for labs using a GE variant. For clustering software other than GE, note that `fsl_sub` makes use of a GE feature allowing the submission of a text file containing a list of commands (one per line) to be run in parallel. All the above tools interact with a compute cluster via a single central script `fsl_sub`; if no cluster is available then this script silently runs all the requested jobs in series. To customise FSL for your local compute cluster and clustering software, refer to the [[https://git.fmrib.ox.ac.uk/fsl/fsl_sub/|fsl_sub documentation]].

----

== Running FSL tools on a GPU or GPU cluster ==

Some FSL tools are able to be accelerated with CUDA-compatible NVIDIA GPUs - this includes `bedpostx_gpu`, `eddy` and `probtrackx2_gpu`. These tools are compiled against the CUDA 10.2 toolkit, but should work with any GPU that supports CUDA 10.2 or newer.

Availability of FSL

FSL is available ready to run for macOS (Intel and M1/M2) and Linux, with Windows computers being supported via the Windows Subsystem for Linux (WSL). Source code is downloaded and installed part of a standard installation, if you wish to compile the code yourself.

Installing FSL

We strongly recommend that the FSL software is downloaded and installed using the fslinstaller.py script available from the link below:

Once you have downloaded the installer, fslinstaller.py, you can use it to install FSL on your computer by following these instructions (click on the appropriate link now, as the next steps for installing are described in the linked pages, not in the sections immediately below here):

To download older ( prior to FSL 6.0.6 ) versions of the FSL, the previous version of the installer can be downloaded here.



Running FSL

Shell setup

The FSL Install script will setup your computer such that you can run the FSL tools from a terminal. See our shell setup guide for details on what this script does. On Linux computers it can also be used to configure FSL for all users on the computer.

Starting the programs

Once your account is configured for FSL use, you can run the FSL tools from the command line; the tools are stored in $FSLDIR/share/fsl/bin and this location will have been added to your terminal's search locations for ease of use.

In general, command-line programs are lower case (e.g. bet), with the GUI version capitalised (e.g. Bet), except on macOS, where you need to append _gui because it can't tell the difference between upper and lower case filenames (e.g. Bet_gui).

To bring up a simple GUI which is just a menu of the main individual FSL GUI tools, just type fsl.


Using FSL with a GridEngine (or similar) computing cluster

Several of the more compute-intensive tools can take advantage of cluster computing, via Son of Grid Engine or http://gridscheduler.sourceforge.net/| Open Grid Scheduler]] (both forks of Sun Grid Engine). We would largely recommend using Son of Grid Engine if you are building a cluster from scratch on a Centos system as they provide RPMs to ease installation. Debian/Ubuntu users should look to install the gridengine package.


Cluster aware tools

  • FEAT will run multiple first-level analyses in parallel if they are setup all together in one GUI setup. At second level, if full FLAME (stages 1+2) is selected then all the slices are processed in parallel.

  • MELODIC will run multiple single-session analyses (or single-session preprocessing if a multi-session/subject analysis is being done) in parallel if they are setup all together in one GUI setup.

  • TBSS will run all registrations in parallel.

  • BEDPOSTX (FDT) low-level diffusion processing will run all slices in parallel.

  • FSLVBM will run all registrations in parallel, both at the template-creation stage and at the final registrations stage.

  • POSSUM will process all slices in parallel.

All the above tools interact with a compute cluster via a single central script fsl_sub; if no cluster is available then this script silently runs all the requested jobs in series. To customise FSL for your local compute cluster and clustering software, refer to the fsl_sub documentation.


Running FSL tools on a GPU or GPU cluster

Some FSL tools are able to be accelerated with CUDA-compatible NVIDIA GPUs - this includes bedpostx_gpu, eddy and probtrackx2_gpu. These tools are compiled against the CUDA 10.2 toolkit, but should work with any GPU that supports CUDA 10.2 or newer.

 

FslInstallation (last edited 12:52:36 16-02-2024 by PaulMcCarthy)